119 lines
2.8 KiB
JavaScript
119 lines
2.8 KiB
JavaScript
import translations from './translations'
|
|
import numberFormats from './translations/numberFormats'
|
|
|
|
export default {
|
|
build: {
|
|
babel: {
|
|
presets({ isServer }) {
|
|
return [
|
|
[
|
|
require.resolve('@nuxt/babel-preset-app'),
|
|
// require.resolve('@nuxt/babel-preset-app-edge'), // For nuxt-edge users
|
|
{
|
|
buildTarget: isServer ? 'server' : 'client',
|
|
corejs: { version: 3 }
|
|
}
|
|
]
|
|
]
|
|
}
|
|
}
|
|
},
|
|
buildModules: ['@nuxtjs/composition-api/module'],
|
|
css: ['vuetify/dist/vuetify.css', '~/assets/scss/global.scss'],
|
|
env: {
|
|
graphqlApi: process.env.GRAPHQL_API
|
|
},
|
|
head: {
|
|
link: [
|
|
{
|
|
rel: 'apple-touch-icon',
|
|
sizes: '180x180',
|
|
href: '/apple-touch-icon.png'
|
|
},
|
|
{
|
|
rel: 'icon',
|
|
type: 'image/png',
|
|
sizes: '32x32',
|
|
href: '/favicon-32x32.png'
|
|
},
|
|
{
|
|
rel: 'icon',
|
|
type: 'image/png',
|
|
sizes: '16x16',
|
|
href: '/favicon-16x16.png'
|
|
},
|
|
{ rel: 'manifest', href: '/site.webmanifest' },
|
|
{ rel: 'mask-icon', href: '/safari-pinned-tab.svg', color: '#7f0aff' },
|
|
{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' },
|
|
{
|
|
rel: 'stylesheet',
|
|
href: 'https://fonts.googleapis.com/css?family=Roboto:100,300,400,500,700,900|Material+Icons'
|
|
},
|
|
{
|
|
rel: 'stylesheet',
|
|
href: 'https://fonts.googleapis.com/css?family=Material+Icons'
|
|
},
|
|
{
|
|
rel: 'stylesheet',
|
|
href: 'https://cdn.materialdesignicons.com/3.3.92/css/materialdesignicons.min.css'
|
|
}
|
|
],
|
|
meta: [
|
|
{
|
|
name: 'viewport',
|
|
content:
|
|
'width=device-width, initial-scale=1, user-scalable=no, minimal-ui'
|
|
}
|
|
]
|
|
},
|
|
i18n: {
|
|
strategy: 'prefix_and_default',
|
|
detectBrowserLanguage: {
|
|
useCookie: true,
|
|
cookieKey: 'nuxt_i18n_redirected',
|
|
alwaysRedirect: true,
|
|
fallbackLocale: 'sv'
|
|
},
|
|
locales: [
|
|
{
|
|
code: 'en',
|
|
iso: 'en-US'
|
|
},
|
|
{
|
|
code: 'sv',
|
|
iso: 'sv-SE'
|
|
}
|
|
],
|
|
defaultLocale: 'sv',
|
|
vueI18n: {
|
|
fallbackLocale: 'sv',
|
|
messages: translations,
|
|
numberFormats
|
|
}
|
|
},
|
|
modules: [
|
|
'nuxt-i18n',
|
|
'@nuxtjs/sentry',
|
|
'@nuxtjs/vuetify',
|
|
['@nuxtjs/moment', { locales: ['sv'], defaultLocale: 'sv' }]
|
|
],
|
|
plugins: [
|
|
'~/plugins/apollo',
|
|
'~/plugins/composition',
|
|
'~/plugins/hooks',
|
|
'~/plugins/i18n',
|
|
'~/plugins/vue-numeral-filter.js'
|
|
],
|
|
router: {
|
|
middleware: ['auth']
|
|
},
|
|
sentry: {
|
|
dsn: 'https://da2e8d42185a4013909d49955432a116@sentry.io/5187660',
|
|
config: {} // Additional config
|
|
},
|
|
ssr: false,
|
|
vuetify: {
|
|
optionsPath: './vuetify.options.js'
|
|
}
|
|
}
|