-
Notifications
You must be signed in to change notification settings - Fork 1
/
next.config.js
48 lines (40 loc) · 1 KB
/
next.config.js
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
const { i18n } = require('./next-i18next.config')
// const withBundleAnalyzer = require('@next/bundle-analyzer')({
// enabled: process.env.ANALYZE === 'true',
// })
module.exports =
// withImages({
// withBundleAnalyzer({{
{
inlineImageLimit: 1024,
pageExtensions: ['js', 'jsx', 'mdx', 'ts', 'tsx'],
experimental: {
modern: true,
},
i18n,
webpack (config) {
config.module.rules.push({
test: /-asset\.svg$/i,
use: [
{
loader: 'file-loader',
options: {
publicPath: '/_next',
name: 'static/media/[name].[hash].[ext]',
esModule: false,
},
},
],
})
config.module.rules.unshift({
test: /\.svg$/,
exclude: /(node_modules)|(asset\.svg)/,
use: ['@svgr/webpack'],
})
return config
},
images: {
domains: ['google.com'],
},
}
// })