-
Notifications
You must be signed in to change notification settings - Fork 3
/
next.config.js
50 lines (47 loc) · 1.17 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
49
50
const { createVanillaExtractPlugin } = require('@vanilla-extract/next-plugin');
const withVanillaExtract = createVanillaExtractPlugin();
const { PHASE_DEVELOPMENT_SERVER } = require('next/constants');
/** @type {import("next").NextConfig} */
module.exports = (phase, { defaultConfig }) => {
if (phase === PHASE_DEVELOPMENT_SERVER) {
const env = {
chain: '0xa4b1', //arbitrum
confirmedBlocks: 1,
envName: 'dev',
basePath: '/dev'
};
const images = {
domains: [
'bearsdeluxe.mypinata.cloud',
'ipfs.io',
'bafybeidpr6zwp4cou32kxpu3uvdfw6vjtuybdd7rtpbdpys6bvaayypubi.ipfs.w3s.link'
]
};
const devNextConfig = {
reactStrictMode: true,
env: env,
images: images
};
return withVanillaExtract(devNextConfig);
} else {
const env = {
chain: '0xa4b1', //arbitrum
confirmedBlocks: 1,
envName: 'prod',
basePath: '/prod'
};
const images = {
domains: [
'bearsdeluxe.mypinata.cloud',
'ipfs.io',
'bafybeidpr6zwp4cou32kxpu3uvdfw6vjtuybdd7rtpbdpys6bvaayypubi.ipfs.w3s.link'
]
};
const ProdNextConfig = {
reactStrictMode: true,
env: env,
images: images
};
return withVanillaExtract(ProdNextConfig);
}
};