2021-04-24 19:10:28 -07:00
|
|
|
const withBundleAnalyzer = require('@next/bundle-analyzer')({
|
|
|
|
enabled: process.env.ANALYZE === 'true',
|
|
|
|
})
|
|
|
|
|
|
|
|
module.exports = withBundleAnalyzer({
|
2021-04-13 12:48:36 -07:00
|
|
|
target: 'serverless',
|
2021-06-20 17:39:05 -07:00
|
|
|
typescript: {
|
|
|
|
ignoreBuildErrors: true, // TODO: remove this before mainnet
|
|
|
|
},
|
2021-07-18 10:24:15 -07:00
|
|
|
webpack(config, { isServer }) {
|
|
|
|
// Fixes npm packages that depend on `fs` module
|
|
|
|
if (!isServer) {
|
|
|
|
config.node = {
|
|
|
|
fs: 'empty',
|
|
|
|
}
|
|
|
|
}
|
2021-03-30 15:47:08 -07:00
|
|
|
config.module.rules.push({
|
|
|
|
test: /\.svg$/,
|
|
|
|
use: ['@svgr/webpack'],
|
|
|
|
})
|
|
|
|
|
|
|
|
return config
|
|
|
|
},
|
2021-07-17 06:49:52 -07:00
|
|
|
async redirects() {
|
|
|
|
return [
|
|
|
|
{
|
|
|
|
source: '/',
|
2021-07-18 07:17:52 -07:00
|
|
|
destination: '/spot/BTC',
|
2021-07-17 06:49:52 -07:00
|
|
|
permanent: false,
|
|
|
|
},
|
|
|
|
]
|
|
|
|
},
|
2021-04-24 19:10:28 -07:00
|
|
|
})
|