-
Notifications
You must be signed in to change notification settings - Fork 1
/
nuxt.config.ts
56 lines (54 loc) · 1.67 KB
/
nuxt.config.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
import { defineNuxtConfig } from 'nuxt/config'
import vuetify, { transformAssetUrls } from 'vite-plugin-vuetify'
// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
modules: [
'@nuxtjs/i18n',
(_options, nuxt) => {
nuxt.hooks.hook('vite:extendConfig', (config) => {
// @ts-expect-error
config.plugins.push(vuetify({ autoImport: true }))
})
}
],
devtools: { enabled: false },
i18n: {
vueI18n: './i18n.config.ts' // if you are using custom path, default
},
runtimeConfig: {
public: {
API: process.env.NUXT_APP_API,
API_REF: process.env.NUXT_APP_APIREF,
IS_MAINTENANCE: process.env.NUXT_IS_MAINTENANCE,
MAINTENANCE_MESSAGE: process.env.NUXT_MAINTENANCE_MESSAGE
}
},
routeRules: {
'/resultats/**': { ssr: false },
'/resultats': { ssr: false },
'/apropos' : { prerender: true}
},
nitro: {
compressPublicAssets: true,
},
app: {
head: {
link: [{ rel: 'stylesheet', media: 'print', onload:"this.onload=null;this.removeAttribute('media')", href: 'https://fonts.googleapis.com/css?family=Roboto:100,300,400,500,700,900&display=swap' }, {rel:"stylesheet preload prefetch", href: 'https://fonts.googleapis.com/css?family=Roboto:100,300,400,500,700,900', as:"style", crossorigin: '', type: 'text/css' }, {rel:'preconnect', href:'https://fonts.gstatic.com'},
{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' },
],
htmlAttrs: {
lang: 'fr',
},
}
},
build: {
transpile: ['vuetify', '@vuepic/vue-datepicker'],
},
vite: {
vue: {
template: {
transformAssetUrls,
},
},
},
});