-
Notifications
You must be signed in to change notification settings - Fork 4
/
nuxt.config.ts
124 lines (122 loc) · 2.43 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
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
import rssPosts from './rss.js'
// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
vue: {
compilerOptions: {
isCustomElement: (tag) => [].includes(tag),
},
},
extends: ['@nuxt/ui-pro'],
modules: [
'nuxt-gtag',
'@nuxt/content',
'@nuxt/ui',
'@nuxthq/studio',
'@nuxtjs/fontaine',
'@nuxtjs/sitemap',
// ! weird error, disable for a while
// "@nuxtjs/feed",
// ! cant fetch twimoji error, so disable for a while
// 'nuxt-og-image'
],
gtag: {
id: 'G-P6HBJNW6QT'
},
site: {
url: 'https://lionad.art',
},
nitro: {
prerender: {
crawlLinks: true,
routes: ['/', '/sitemap.xml'],
},
},
// @ts-ignore see https://github.com/nuxt-community/feed-module
feed: {
path: '/rss.xml',
async create(feed) {
feed.options = {
title: 'Lionad\'s blog',
link: 'https://www.lionad.art/rss.xml',
description: 'Feed for Lionad\'s Blog',
}
rssPosts.forEach((post) => {
feed.addItem({
title: post.title,
id: post.url,
link: post.url,
description: post.description,
content: post.content,
})
})
feed.addCategory('Lionad')
feed.addContributor({
name: 'Lionad',
email: '[email protected]',
link: 'https://www.lionad.art',
})
},
},
hooks: {
'components:extend': (components) => {
const globals = components.filter((c) =>
[
'Commend',
'Compare',
'ReadBase64',
'LLink',
'Spark',
'UButton',
'UIcon',
'AspectRatio',
].includes(c.pascalName)
)
globals.forEach((c) => (c.global = true))
},
},
ui: {
icons: ['heroicons', 'simple-icons'],
},
content: {
highlight: {
theme: {
default: 'github-light',
dark: 'github-dark',
sepia: 'monokai',
},
},
},
routeRules: {
'/api/search.json': {
prerender: true
},
},
devtools: {
enabled: false,
},
typescript: {
strict: false,
},
mdc: {
highlight: {
langs: [
'bash',
'cpp',
'css',
'glsl',
'html',
'less',
'stylus',
'js',
'powershell',
'scss',
'shell',
'ts',
'vue',
'makefile',
'mermaid',
'csharp',
],
},
},
})