-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnext.config.js
More file actions
43 lines (39 loc) · 972 Bytes
/
next.config.js
File metadata and controls
43 lines (39 loc) · 972 Bytes
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
module.exports = {
swcMinify: true,
env: {
appVersion: process.env.npm_package_version,
},
/* config options here */
webpack(config, { isServer, dev: isDevelopmentMode }) {
if (!isServer) {
config.resolve.fallback.fs = false;
config.resolve.fallback.module = false;
}
config.module.rules.push({
test: /\.svg$/,
use: ['@svgr/webpack'],
});
config.module.rules.push({
test: /\.po$/,
use: [
{
loader: 'ignore-loader',
},
],
});
// Attempt to ignore storybook files when doing a production build,
// see also: https://github.com/vercel/next.js/issues/1914
if (!isDevelopmentMode) {
config.module.rules.push({
test: /\.stories.(js|tsx?)/,
loader: 'ignore-loader',
});
}
return config;
},
poweredByHeader: false,
images: {
domains: ['tailwindui.com', 'images.unsplash.com'],
path: 'https://noop/',
},
};