-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnext.config.js
More file actions
63 lines (60 loc) · 1.47 KB
/
next.config.js
File metadata and controls
63 lines (60 loc) · 1.47 KB
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
51
52
53
54
55
56
57
58
59
60
61
62
63
/** @type {import('next').NextConfig} */
const withPWA = require('next-pwa');
const runtimeCaching = require('next-pwa/cache');
const { i18n } = require('./next-i18next.config');
const nextConfig = {
reactStrictMode: true,
i18n,
pwa: {
disable: process.env.NODE_ENV === 'development',
dest: 'public',
runtimeCaching,
},
images: {
domains: [
'pickbazarlaravel.s3.ap-southeast-1.amazonaws.com',
'lh3.googleusercontent.com',
'localhost',
'127.0.0.1',
'i.pravatar.cc',
'img.freepik.com',
'assets.bacardicontenthub.com',
'toppng.com',
'seekpng.com',
'www.seekpng.com',
'pikpng.com',
'www.pikpng.com',
'foremostng.com',
'www.nicepng.com',
'www.pngkit.com',
'www.vhv.rs',
's.wine.style',
'chupapap.com',
'res.cloudinary.com'
],
},
...(process.env.FRAMEWORK_PROVIDER === 'graphql' && {
webpack(config, options) {
config.module.rules.push({
test: /\.graphql$/,
exclude: /node_modules/,
use: [options.defaultLoaders.babel, { loader: 'graphql-let/loader' }],
});
config.module.rules.push({
test: /\.ya?ml$/,
type: 'json',
use: 'yaml-loader',
});
return config;
},
}),
...(process.env.NODE_ENV === 'production' && {
typescript: {
ignoreBuildErrors: true,
},
eslint: {
ignoreDuringBuilds: true,
},
}),
};
module.exports = withPWA(nextConfig);