-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathnext.config.js
32 lines (31 loc) · 874 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
module.exports = {
// Prefer loading of ES Modules over CommonJS
experimental: { esmExternals: true },
// Support MDX files as pages:
pageExtensions: ['md', 'mdx', 'tsx', 'ts', 'jsx', 'js'],
// Support loading `.md`, `.mdx`:
webpack(config, options) {
config.module.rules.push({
test: /\.mdx?$/,
use: [
// The default `babel-loader` used by Next:
options.defaultLoaders.babel,
{
loader: '@mdx-js/loader',
/** @type {import('@mdx-js/loader').Options} */
options: {
/* jsxImportSource: …, otherOptions… */
}
}
]
});
return config;
},
experimental: { images: { layoutRaw: true } },
reactStrictMode: false,
// Due to the way that GH pages works, we can't use Next.js optimized images.
images: {
loader: 'akamai',
path: ''
}
};