2023-03-07 15:23:54 +00:00
|
|
|
/** @type {import('next').NextConfig} */
|
2023-03-12 19:06:21 +00:00
|
|
|
|
2023-03-12 19:21:48 +00:00
|
|
|
const nextConfig = {
|
2023-03-07 15:23:54 +00:00
|
|
|
experimental: {
|
|
|
|
appDir: true,
|
|
|
|
},
|
2023-03-09 17:01:40 +00:00
|
|
|
webpack(config) {
|
|
|
|
config.module.rules.push({
|
|
|
|
test: /\.svg$/,
|
|
|
|
use: ["@svgr/webpack"],
|
|
|
|
}); // 针对 SVG 的处理规则
|
2023-03-07 15:23:54 +00:00
|
|
|
|
2023-03-09 17:01:40 +00:00
|
|
|
return config;
|
2023-03-23 16:01:00 +00:00
|
|
|
}
|
2023-03-12 19:21:48 +00:00
|
|
|
};
|
2023-03-09 17:01:40 +00:00
|
|
|
|
2023-03-27 05:49:26 +00:00
|
|
|
if (process.env.DOCKER) {
|
|
|
|
nextConfig.output = 'standalone'
|
|
|
|
}
|
|
|
|
|
2023-03-09 17:01:40 +00:00
|
|
|
module.exports = nextConfig;
|