-
-
Notifications
You must be signed in to change notification settings - Fork 36
/
next.config.mjs
93 lines (92 loc) · 2.56 KB
/
next.config.mjs
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
const isDev = process.argv.indexOf('dev') !== -1
const isBuild = process.argv.indexOf('build') !== -1
if (!process.env.VELITE_STARTED && (isDev || isBuild)) {
process.env.VELITE_STARTED = '1'
const { build } = await import('velite')
await build({ watch: isDev, clean: !isDev })
}
/** @type {import('next').NextConfig} */
export default {
experimental: {
optimizePackageImports: ["shiki"]
},
async redirects() {
return [
{
source: "/d/:path*",
destination: "/:path*",
permanent: true
},
{
source: "/docs",
destination: "/docs/getting-started/installation",
permanent: false
},
{
source: "/docs/components/layouts/aside",
destination: "/docs/components/layouts/sidebar",
permanent: false
},
{
source: "/d/accordion",
destination: "/docs/components/navigation/disclosure-group",
permanent: false
},
{
source: "/accordion",
destination: "/docs/components/navigation/disclosure-group",
permanent: false
},
{
source: "/aside",
destination: "/docs/components/layouts/sidebar",
permanent: false
},
{
source: "/design-system",
destination: "/docs/getting-started/installation",
permanent: false
},
{
source: "/docs/components/collections/accordion",
destination: "/docs/components/navigation/disclosure-group",
permanent: true
},
{
source: "/docs/components/controls/command",
destination: "/docs/components/controls/command-menu",
permanent: false
},
{
source: "/docs/components/forms/select",
destination: "/docs/components/pickers/select",
permanent: false
},
{
source: "/docs/components/forms/select",
destination: "/docs/components/pickers/select",
permanent: false
},
{
source: "/docs/components/statuses/toaster",
destination: "/docs/components/statuses/toast",
permanent: true
},
{
source: "/docs/components/collections/carousel",
destination: "/docs/components/media/carousel",
permanent: true
},
{
source: "/docs/components/forms/choicebox",
destination: "/docs/components/collections/choicebox",
permanent: true
},
{
source: "/docs/components/forms/multiple-select",
destination: "/docs/components/pickers/multiple-select",
permanent: false
}
]
}
}