-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnuxt.config.ts
More file actions
109 lines (107 loc) · 2.42 KB
/
nuxt.config.ts
File metadata and controls
109 lines (107 loc) · 2.42 KB
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
import svgLoader from 'vite-svg-loader'
export default defineNuxtConfig({
experimental: {
appManifest: false,
},
app: {
head: {
htmlAttrs: {
lang: 'en',
},
meta: [
{
name: 'viewport',
content: 'width=device-width, initial-scale=1',
},
{
charset: 'utf-8',
},
{
name: 'description',
content:
'Modrunner levels up your Discord communities by providing a free and easy to use Discord bot that allows both creators and users to find, share and follow modding projects on some of the most popular platforms.',
},
{
name: 'publisher',
content: 'Modrunner',
},
{
name: 'og:title',
content: 'Modrunner',
},
{
name: 'apple-mobile-web-app-title',
content: 'Modrunner',
},
// {
// name: 'theme-color',
// content: '#ffffff'
// },
{
name: 'color-scheme',
content: 'dark light',
},
{
name: 'og:description',
content: 'The ultimate resource for modding communities',
},
{
name: 'og:type',
content: 'website',
},
{
name: 'og:url',
content: 'https://modrunner.net',
},
// {
// name: 'og:image',
// content:
// },
{
name: 'twitter:card',
content: 'summary',
},
{
name: 'twitter:site',
content: '@modrunnerbot',
},
],
link: [{ rel: 'icon', href: './favicon.ico' }],
},
},
build: {
transpile: ['vue-sonner'],
},
content: {
highlight: {
theme: 'material-default',
},
},
css: ['~/assets/styles/components.scss', '~/assets/styles/fonts.scss', '~/assets/styles/global.scss', '~/assets/styles/layout.scss'],
modules: ['dayjs-nuxt', '@nuxt/content', 'floating-vue/nuxt'],
runtimeConfig: {
discordClientSecret: process.env.NUXT_DISCORD_CLIENT_SECRET ?? '',
apiKey: process.env.NUXT_API_KEY ?? '',
apiUrl: process.env.NUXT_API_URL ?? '',
public: {
discordClientId: process.env.NUXT_PUBLIC_DISCORD_CLIENT_ID ?? '',
owner: 'modrunner',
slug: 'website',
branch: process.env.CF_PAGES_BRANCH ?? 'unknown',
hash: process.env.CF_PAGES_COMMIT_SHA ?? 'unknown',
baseUrl: getDomain(),
},
},
vite: {
plugins: [svgLoader()],
},
})
function getDomain() {
if (process.env.CF_PAGES_BRANCH === 'production') {
return 'https://modrunner.net'
} else if (process.env.CF_PAGES_BRANCH === 'staging') {
return 'https://staging.modrunner.net'
} else {
return 'http://localhost:3000'
}
}