-
Notifications
You must be signed in to change notification settings - Fork 0
/
next.config.js
36 lines (30 loc) · 914 Bytes
/
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
const withCSS = require('@zeit/next-css')
const withPlugins = require('next-compose-plugins')
const optimizedImages = require('next-optimized-images')
// https://github.com/giuseppeg/styled-jsx-plugin-postcss
// https://github.com/zeit/styled-jsx/issues/560#issuecomment-493112657
// https://github.com/zeit/next.js#built-in-css-support
// https://github.com/cyrilwanner/next-compose-plugins
const nextConfig = {
webpack: (config, options) => {
// modify the `config` here
return config;
},
}
module.exports = withPlugins([
[optimizedImages, {
imagesName: '[name]-[hash].[ext]',
handleImages: ['jpeg', 'png', 'svg', 'webp', 'gif'],
optimizeImages: true,
svgo: {
},
optipng: {
optimizationLevel: 3,
},
}],
[withCSS, {
plugins: {
'postcss-css-nested': {}
}
}]
], nextConfig)