-
Notifications
You must be signed in to change notification settings - Fork 1
/
next.config.js
21 lines (17 loc) · 702 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
const withPlugins = require('next-compose-plugins');
const optimizedImages = require('next-optimized-images');
const nextConfiguration = {
target: 'serverless', //will output independent pages that don't require a monolithic server. It's only compatible with next start or Serverless deployment platforms (like ZEIT Now) — you cannot use the custom server API.
};
module.exports = withPlugins([optimizedImages], nextConfiguration);
module.exports = {
webpack5: true,
experiments: {
topLevelAwait: true,
},
webpack: (config) => {
config.experiments = { ...config.experiments, ...{ topLevelAwait: true }};
config.resolve.fallback = { fs: false };
return config;
},
};