forked from albionstatus/albionstatus-website
-
Notifications
You must be signed in to change notification settings - Fork 0
/
nuxt.config.js
129 lines (112 loc) · 2.61 KB
/
nuxt.config.js
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
import { colors } from './tailwind/values'
const analyticsUA = 'UA-62902757-9'
const isDev = process.env.NODE_ENV !== 'production'
const isProd = !isDev
const baseUrl = 'https://www.albionstatus.com'
export default {
modern: isProd && 'client',
env: {
baseUrl
},
head: {
title: '',
titleTemplate: s => s ? `${s} | AlbionStatus` : 'AlbionStatus - Is Albion Down?',
noscript: [{ innerHTML: 'This website requires JavaScript.' }]
},
router: {
trailingSlash: true
},
generate: {
fallback: true
},
meta: {
name: 'AlbionStatus - Albion Online server status',
author: 'Developmint',
description: 'AlbionStatus is the only reliable Albion Online server status tracker. Find out if Albion is down' +
' in a splitsecond, no matter if it is the daily maintenance or an outage.',
ogSiteName: 'AlbionStatus',
mobileAppIOs: true,
ogHost: 'https://albionstatus.com',
twitterSite: '@AlbionStatus',
twitterCard: 'summary'
},
modules: [
'@nuxtjs/axios',
['@nuxtjs/google-analytics', {
id: analyticsUA,
disabled: () => document.cookie.includes('ga_optout=true'),
debug: {
sendHitTask: isProd
},
set: [
{ field: 'anonymizeIp', value: true }
]
}],
['@nuxtjs/google-adsense', {
id: 'ca-pub-4749840658812364',
analyticsUacct: analyticsUA,
test: isDev
}],
'@nuxtjs/pwa',
'nuxt-svg-loader',
'@nuxtjs/netlify-files',
'@nuxtjs/sitemap'
],
axios: {
debug: isDev,
baseURL: 'https://api.albionstatus.com'
},
loading: { color: colors.developmint['500'] },
manifest: {
lang: 'en',
short_name: 'AlbionStatus',
start_url: '/',
display: 'standalone',
background_color: '#FFFFFF',
orientation: 'any',
theme_color: colors.green['300']
},
buildModules: [
'@nuxtjs/tailwindcss'
],
tailwindcss: {
configPath: '~/tailwind.config.js',
cssPath: '~/assets/css/app.pcss'
},
purgeCSS: {
whitelistPatterns: [/fade/]
},
sitemap: {
hostname: baseUrl,
exclude: [
'/legal',
'/privacy'
],
defaults: {
changefreq: 'daily',
priority: 1,
lastmodrealtime: true
},
trailingSlash: true
},
netlifyFiles: {
existingFilesDirectory: './netlify'
},
build: {
publicPath: '/assets/',
extend (config, ctx) {
if (!ctx.isClient) {
return
}
if (!ctx.isDev) {
return
}
config.module.rules.push({
enforce: 'pre',
test: /\.(js|vue)$/,
loader: 'eslint-loader',
exclude: /(node_modules)/
})
}
}
}