forked from udecode/plate
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnext.config.js
More file actions
39 lines (34 loc) · 973 Bytes
/
Copy pathnext.config.js
File metadata and controls
39 lines (34 loc) · 973 Bytes
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
const path = require('path');
const alias = require('../../../config/aliases');
Object.keys(alias).forEach((key) => {
alias[key] = path.resolve(__dirname, `../../../packages/${alias[key]}/src`);
});
/**
* @type {import('next').NextConfig}
*/
const config = {
experimental: {
// Prefer loading of ES Modules over CommonJS
// @link {https://nextjs.org/blog/next-11-1#es-modules-support|Blog 11.1.0}
// @link {https://github.com/vercel/next.js/discussions/27876|Discussion}
esmExternals: true,
// Experimental monorepo support
// @link {https://github.com/vercel/next.js/pull/22867|Original PR}
// @link {https://github.com/vercel/next.js/discussions/26420|Discussion}
externalDir: true,
},
webpack(cfg) {
cfg.resolve.alias = {
...cfg.resolve.alias,
...alias,
};
return cfg;
},
typescript: {
ignoreBuildErrors: true,
},
eslint: {
ignoreDuringBuilds: true,
},
};
module.exports = config;