1
0
mirror of https://github.com/kamranahmedse/developer-roadmap.git synced 2025-02-23 19:13:19 +01:00
developer-roadmap/next.config.js

31 lines
580 B
JavaScript
Raw Normal View History

2021-08-20 15:55:39 +02:00
const path = require('path');
const rehypePrism = require('@mapbox/rehype-prism');
const withMDX = require('@next/mdx')({
extension: /\.(md|mdx)?$/,
options: {
rehypePlugins: [rehypePrism]
}
});
let nextConfig = {
2021-08-01 13:08:35 +02:00
reactStrictMode: true,
2021-08-19 15:01:18 +02:00
poweredByHeader: false,
2021-08-20 15:55:39 +02:00
webpack(config, options) {
config.resolve.modules.push(path.resolve('./'));
2021-08-20 17:06:26 +02:00
// Transforms SVGs to components
config.module.rules.push({
test: /\.svg$/,
use: ['@svgr/webpack']
});
2021-08-20 15:55:39 +02:00
return config;
}
};
nextConfig = withMDX(nextConfig);
module.exports = nextConfig;