-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnext.config.js
More file actions
117 lines (116 loc) · 3.11 KB
/
next.config.js
File metadata and controls
117 lines (116 loc) · 3.11 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
110
111
112
113
114
115
116
117
/** @type {import('next').NextConfig} */
const nextConfig = {
reactStrictMode: true,
images: {
remotePatterns: [
{
protocol: 'https',
hostname: 'images.unsplash.com',
},
{
protocol: 'https',
hostname: 'ui-avatars.com',
},
],
},
// swcMinify is deprecated in Next.js 16+ (enabled by default)
// Enable compression (handled by Next.js automatically in production)
compress: true,
// Enable source maps for production builds to help with debugging and Lighthouse audits
productionBrowserSourceMaps: false, // Disable to reduce bundle size
// Optimize bundle splitting
experimental: {
optimizePackageImports: ['lucide-react', 'framer-motion'],
},
// Reduce JavaScript bundle size
compiler: {
removeConsole: process.env.NODE_ENV === 'production' ? {
exclude: ['error', 'warn'],
} : false,
},
async redirects() {
return [
{
source: '/docs/complete-reference',
destination: '/docs/reference',
permanent: true,
},
{
source: '/docs/reference/complete',
destination: '/docs/reference',
permanent: true,
},
{
source: '/docs/complete-reference/known-limitations',
destination: '/docs/reference/limitations',
permanent: true,
},
{
source: '/docs/logicstamp-context/monorepo',
destination: '/docs/guides/monorepo',
permanent: true,
},
{
source: '/docs/guides/hashes',
destination: '/docs/reference/hashes',
permanent: true,
},
{
source: '/docs/guides/uifb',
destination: '/docs/reference/hashes',
permanent: true,
},
{
source: '/docs/guides/uif-contracts',
destination: '/docs/reference/uif-contracts',
permanent: true,
},
{
source: '/docs/logicstamp-context/schema',
destination: '/docs/reference/schema',
permanent: true,
},
{
source: '/docs/logicstamp-context/frameworks',
destination: '/docs/frameworks',
permanent: true,
},
{
source: '/docs/logicstamp-context/frameworks/:path*',
destination: '/docs/frameworks/:path*',
permanent: true,
},
{
source: '/docs/logicstamp-context/ui-frameworks',
destination: '/docs/ui-frameworks',
permanent: true,
},
{
source: '/docs/logicstamp-context/ui-frameworks/:path*',
destination: '/docs/ui-frameworks/:path*',
permanent: true,
},
{
source: '/docs/logicstamp-context/cli/getting-started',
destination: '/docs/cli/getting-started',
permanent: true,
},
{
source: '/docs/logicstamp-context/cli',
destination: '/docs/cli',
permanent: true,
},
{
source: '/docs/logicstamp-context/:path*',
destination: '/docs/cli/:path*',
permanent: true,
},
{
source: '/docs/logicstamp-context',
destination: '/docs/cli',
permanent: true,
},
]
},
}
module.exports = nextConfig