const path = require('path'); const createMDX = require('@next/mdx'); const childProcess = require('child_process'); const isProd = process.env.NODE_ENV === 'production'; /** @type {import('next').NextConfig} */ const nextConfig = { output: 'export', reactStrictMode: true, sassOptions: { includePaths: [ path.join(__dirname, 'styles') ] }, generateBuildId: async () => { return childProcess.execSync('git rev-parse HEAD').toString().trim(); }, pageExtensions: [ 'js', 'jsx', 'md', 'mdx', 'ts', 'tsx' ], assetPrefix: isProd ? 'http://localhost:3000/flint/website/pages' : undefined }; module.exports = createMDX({ mdPlugins: [ import('rehype-highlight') ] })(nextConfig);