Dan Abramov 2 years ago
parent
commit
c741dd49e3
  1. 4
      beta/src/pages/[[...markdownPath]].js

4
beta/src/pages/[[...markdownPath]].js

@ -55,7 +55,7 @@ function reviveNodeOnClient(key, val) {
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// ~~~~ IMPORTANT: BUMP THIS IF YOU CHANGE ANY CODE BELOW ~~~ // ~~~~ IMPORTANT: BUMP THIS IF YOU CHANGE ANY CODE BELOW ~~~
const DISK_CACHE_BREAKER = 6; const DISK_CACHE_BREAKER = 7;
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// Put MDX output into JSON for client. // Put MDX output into JSON for client.
@ -112,7 +112,7 @@ export async function getStaticProps(context) {
// This will break the prepareMDX() call below. // This will break the prepareMDX() call below.
let mdxWithFakeImports = let mdxWithFakeImports =
mdx + mdx +
'\n' + '\n\n' +
mdxComponentNames mdxComponentNames
.map((key) => 'import ' + key + ' from "' + key + '";\n') .map((key) => 'import ' + key + ' from "' + key + '";\n')
.join('\n'); .join('\n');

Loading…
Cancel
Save