This commit is contained in:
DefectingCat
2022-01-14 10:29:47 +08:00
parent 882d65d474
commit 3f27989654
4 changed files with 798 additions and 17 deletions

View File

@ -1,6 +1,20 @@
/** @type {import('next').NextConfig} */
const nextConfig = {
reactStrictMode: true,
}
module.exports = nextConfig
const withMDX = require('@next/mdx')({
extension: /\.mdx?$/,
options: {
remarkPlugins: [],
rehypePlugins: [],
},
});
module.exports = withMDX({
reactStrictMode: true,
pageExtensions: ['ts', 'tsx', 'js', 'jsx', 'md', 'mdx'],
swcMinify: true,
experimental: {
// Native Node.js APIs are not supported in the Edge Runtime with `concurrentFeatures` enabled. Found `fs` imported.
// concurrentFeatures: true,
// serverComponents: true,
},
});

View File

@ -8,11 +8,15 @@
"lint": "next lint"
},
"dependencies": {
"@mdx-js/loader": "^1.6.22",
"@mdx-js/react": "^1.6.22",
"@next/mdx": "^12.0.8",
"next": "12.0.8",
"react": "17.0.2",
"react-dom": "17.0.2"
"react": "^17.0.2",
"react-dom": "^17.0.2"
},
"devDependencies": {
"@types/mdx-js__react": "^1.5.5",
"@types/node": "17.0.8",
"@types/react": "17.0.38",
"autoprefixer": "^10.4.2",

View File

@ -5,6 +5,7 @@ import { NextPage } from 'next';
import { ReactElement, ReactNode } from 'react';
import useRouterLoading from 'lib/hooks/useRouteLoading';
import Head from 'next/head';
import { MDXProvider } from '@mdx-js/react';
type NextPageWithLayout = NextPage & {
// eslint-disable-next-line no-unused-vars

784
yarn.lock

File diff suppressed because it is too large Load Diff