@@ -26,13 +26,13 @@ export default defineNuxtConfig({
2626 '@nuxt/scripts' ,
2727 'reka-ui/nuxt' ,
2828 '@nuxtjs/prismic' ,
29- ! environment . useNuxtHub && '@nuxtjs/seo' , // Skip SEO for NuxtHub builds
3029 '@nuxtjs/device' ,
3130 '@nuxt/fonts' ,
3231 '@pinia/colada-nuxt' ,
3332 ! environment . useNuxtHub && 'nuxt-module-feed' , // Skip feed for NuxtHub builds
33+ ! environment . useNuxtHub && 'nuxt-og-image' , // Enable og-image only when not on NuxtHub
34+ '@nuxtjs/seo' ,
3435 'nuxt-safe-runtime-config' ,
35- 'nuxt-security' ,
3636 'motion-v/nuxt' ,
3737 './modules/prerender-routes' ,
3838 environment . useNuxtHub && '@nuxthub/core' ,
@@ -53,81 +53,6 @@ export default defineNuxtConfig({
5353 } ,
5454 } ,
5555
56- security : {
57- hidePoweredBy : true ,
58- headers : {
59- xFrameOptions : 'SAMEORIGIN' ,
60- contentSecurityPolicy : {
61- 'script-src' : environment . environment . isLocal
62- ? [
63- '\'self\'' ,
64- '\'unsafe-inline\'' ,
65- '\'unsafe-eval\'' ,
66- 'https://static.cdn.prismic.io' ,
67- 'https://nimiq.prismic.io' ,
68- 'https://www.googletagmanager.com' ,
69- 'https://www.google-analytics.com' ,
70- 'https://stats.nimiq-network.com' ,
71- ]
72- : [
73- '\'strict-dynamic\'' ,
74- '\'nonce-{{nonce}}\'' ,
75- '\'unsafe-inline\'' ,
76- 'https://static.cdn.prismic.io' ,
77- ] ,
78- 'script-src-attr' : environment . environment . isLocal
79- ? [ '\'unsafe-inline\'' ]
80- : [ '\'none\'' ] ,
81- 'style-src' : [
82- '\'self\'' ,
83- 'https:' ,
84- '\'unsafe-inline\'' ,
85- ] ,
86- 'base-uri' : [ '\'none\'' ] ,
87- 'font-src' : [
88- '\'self\'' ,
89- 'https:' ,
90- 'data:' ,
91- ] ,
92- 'object-src' : [ '\'none\'' ] ,
93- 'frame-src' : [ '\'self\'' , 'https://nimiq.prismic.io' , 'https://map.nimiq.com' ] ,
94- 'connect-src' : [
95- '\'self\'' ,
96- 'wss://nimiq-website.je-cf9.workers.dev' ,
97- 'https://nimiq-website.je-cf9.workers.dev' ,
98- 'https://www.google-analytics.com' ,
99- 'https://analytics.google.com' ,
100- 'https://stats.g.doubleclick.net' ,
101- 'https://stats.nimiq-network.com' ,
102- 'https://mycbdmurjytbdahjljoh.supabase.co' ,
103- 'https://nimiq.prismic.io' ,
104- 'https://dev.validators-api-mainnet.pages.dev' ,
105- 'https://validators-api-mainnet.nuxt.dev' ,
106- 'https://nimiq.cdn.prismic.io' ,
107- ] ,
108- 'upgrade-insecure-requests' : true ,
109- 'img-src' : [
110- '\'self\'' ,
111- 'data:' ,
112- 'https://nimiq.prismic.io' ,
113- 'https://static.cdn.prismic.io' ,
114- 'https://images.prismic.io' ,
115- 'https://nimiq.cdn.prismic.io' ,
116- 'https://www.google-analytics.com' ,
117- 'https://www.googletagmanager.com' ,
118- 'https://*.google.com' ,
119- 'https://*.google.co.th' ,
120- 'https://*.google.co.uk' ,
121- 'https://*.google.de' ,
122- 'https://*.google.fr' ,
123- ] ,
124- } ,
125- crossOriginOpenerPolicy : false ,
126- crossOriginEmbedderPolicy : false ,
127- xXSSProtection : '1; mode=block' ,
128- } ,
129- } ,
130-
13156 devtools : { enabled : true } ,
13257
13358 components : [
@@ -382,14 +307,15 @@ export default defineNuxtConfig({
382307 } ,
383308
384309 // Disable og-image generation on NuxtHub (Cloudflare) due to @resvg/resvg-js native bindings incompatibility
385- ogImage : environment . useNuxtHub
386- ? undefined
387- : {
388- fonts : [ 'Mulish:400' , 'Mulish:700' ] ,
389- } ,
310+ // Moved into conditional spread below to appease TS/ESLint config typing
390311
391312 // Feed configuration - skip for NuxtHub builds
392313 ...( ! environment . useNuxtHub && {
314+ // eslint-disable-next-line ts/ban-ts-comment
315+ // @ts -ignore Provided by nuxt-og-image module
316+ ogImage : {
317+ fonts : [ 'Mulish:400' , 'Mulish:700' ] ,
318+ } ,
393319 feed : {
394320 sources : [
395321 { path : '/feed.xml' , type : 'rss2' , cacheTime : 0 } ,
0 commit comments