26 lines
574 B
JavaScript
26 lines
574 B
JavaScript
import createMDX from '@next/mdx';
|
|
import rehypePrettyCode from 'rehype-pretty-code';
|
|
|
|
/** @type {import('next').NextConfig} */
|
|
const nextConfig = {
|
|
pageExtensions: ['js', 'jsx', 'md', 'mdx', 'ts', 'tsx'],
|
|
transpilePackages: ['@newspaperui/components', '@newspaperui/theme', '@newspaperui/utils'],
|
|
};
|
|
|
|
const withMDX = createMDX({
|
|
extension: /\.mdx?$/,
|
|
options: {
|
|
rehypePlugins: [
|
|
[
|
|
rehypePrettyCode,
|
|
{
|
|
theme: 'github-dark',
|
|
keepBackground: false,
|
|
},
|
|
],
|
|
],
|
|
},
|
|
});
|
|
|
|
export default withMDX(nextConfig);
|