44 lines
981 B
JavaScript
44 lines
981 B
JavaScript
/** @type {import('next').NextConfig} */
|
|
const nextConfig = {
|
|
webpack: (config, { isServer }) => {
|
|
// Handle node: protocol imports
|
|
if (!isServer) {
|
|
config.resolve.fallback = {
|
|
...config.resolve.fallback,
|
|
buffer: require.resolve('buffer/'),
|
|
stream: require.resolve('stream-browserify'),
|
|
util: require.resolve('util/'),
|
|
};
|
|
}
|
|
return config;
|
|
},
|
|
eslint: {
|
|
ignoreDuringBuilds: true,
|
|
},
|
|
typescript: {
|
|
ignoreBuildErrors: true,
|
|
},
|
|
images: {
|
|
unoptimized: true,
|
|
},
|
|
experimental: {
|
|
webpackBuildWorker: true,
|
|
parallelServerBuildTraces: true,
|
|
parallelServerCompiles: true,
|
|
},
|
|
async headers() {
|
|
return [
|
|
{
|
|
source: '/:path*',
|
|
headers: [
|
|
{
|
|
key: 'Content-Security-Policy',
|
|
value: "frame-ancestors 'self' https://espace.slm-lab.net https://connect.slm-lab.net"
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|
|
};
|
|
|
|
module.exports = nextConfig; |