-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathnuxt.config.ts
105 lines (94 loc) · 2.85 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
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
import { fileURLToPath } from 'url'
export default defineNuxtConfig({
app: {
head: {
title: 'Kut - A modern link management tool',
htmlAttrs: {
lang: 'en',
},
charset: 'utf-8',
viewport: 'width=device-width, initial-scale=1',
meta: [
{ hid: 'og:title', name: 'og:title', content: 'Kut - A modern link management tool' },
{ name: 'format-detection', content: 'telephone=no' },
],
link: [
{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' },
{
rel: 'stylesheet',
type: 'text/css',
href: 'https://fonts.googleapis.com/css2?family=Inter:wght@100;200;300;400;500;600;700;800;900&display=swap',
},
],
},
pageTransition: {
name: 'fade-in',
mode: 'out-in',
},
layoutTransition: {
name: 'fade-in',
mode: 'out-in',
},
},
typescript: {
typeCheck: true,
},
srcDir: 'src',
serverDir: 'server',
css: ['~/assets/toast.css'],
ui: {
icons: ['ph'],
},
modules: [
'@pinia/nuxt',
'@vueuse/nuxt',
'nuxt-icon',
'@pinia-plugin-persistedstate/nuxt',
'@nuxt/devtools',
'@nuxt/ui',
],
serverHandlers: [
{ route: '/api', handler: '~/server/server.ts' },
{ route: '/api/**', handler: '~/server/server.ts' },
],
nitro: {
plugins: ['~/server/common/helpers/mongo.helper.ts'],
esbuild: {
options: {
tsconfigRaw: {
compilerOptions: {
experimentalDecorators: true,
},
},
},
},
},
build: {
transpile: ['@headlessui/vue', 'vue-tiny-validate'],
},
alias: {
components: fileURLToPath(new URL('./src/components', import.meta.url)),
composables: fileURLToPath(new URL('./src/composables', import.meta.url)),
interfaces: fileURLToPath(new URL('./src/interfaces', import.meta.url)),
services: fileURLToPath(new URL('./src/services', import.meta.url)),
store: fileURLToPath(new URL('./src/store', import.meta.url)),
utils: fileURLToPath(new URL('./src/utils', import.meta.url)),
server: fileURLToPath(new URL('./src/server', import.meta.url)),
},
runtimeConfig: {
public: {
apiBaseUrl: process.env.API_BASE_URL,
githubClientId: process.env.GITHUB_CLIENT_ID,
},
dbUrl: process.env.DB_URL,
dbName: process.env.DB_NAME,
accessTokenSecret: process.env.ACCESS_TOKEN_SECRET,
accessTokenExpiration: process.env.ACCESS_TOKEN_EXPIRATION,
refreshTokenSecret: process.env.REFRESH_TOKEN_SECRET,
refreshTokenExpiration: process.env.REFRESH_TOKEN_EXPIRATION,
accountVerificationTokenSecret: process.env.ACCOUNT_VERIFICATION_TOKEN_SECRET,
accountVerificationTokenExpiration: process.env.ACCOUNT_VERIFICATION_TOKEN_EXPIRATION,
emailApiKey: process.env.SIB_EMAIL_API_KEY,
githubClientSecret: process.env.GITHUB_CLIENT_SECRET,
},
})