diff --git a/pages/blog/[slug].js b/pages/blog/[slug].js index f30c835..19be48d 100644 --- a/pages/blog/[slug].js +++ b/pages/blog/[slug].js @@ -98,7 +98,8 @@ export async function getStaticProps({ params }) { "blog" ); - const markdown = JSON.stringify(Markdown.parse({ post })); + const markdown = JSON.stringify(Markdown.parse({ post: { content: String.raw`${post.content}` } })); + return { props: { post, markdown, nextPost, previousPost }, }; diff --git a/pages/community/opportunities.js b/pages/community/opportunities.js index 28a3ac7..f4bb055 100644 --- a/pages/community/opportunities.js +++ b/pages/community/opportunities.js @@ -25,7 +25,8 @@ export async function getStaticProps({ params }) { if (index === undefined) { index = null; } - const markdown = JSON.stringify(Markdown.parse({ post })); + const markdown = JSON.stringify(Markdown.parse({ post: { content: String.raw`${post.content}` } })); + return { props: { post, markdown, index }, }; diff --git a/pages/community/support.js b/pages/community/support.js index b725966..9c484d1 100644 --- a/pages/community/support.js +++ b/pages/community/support.js @@ -25,7 +25,8 @@ export async function getStaticProps({ params }) { if (index === undefined) { index = null; } - const markdown = JSON.stringify(Markdown.parse({ post })); + const markdown = JSON.stringify(Markdown.parse({ post: { content: String.raw`${post.content}` } })); + return { props: { post, markdown, index }, }; diff --git a/pages/guides/[[...slug]].js b/pages/guides/[[...slug]].js index 0c5b4a2..2cde295 100644 --- a/pages/guides/[[...slug]].js +++ b/pages/guides/[[...slug]].js @@ -83,9 +83,8 @@ export default function GuidePage({ Edit this page on GitHub @@ -308,8 +307,7 @@ export async function getStaticProps({ params }) { "weight" ) || null; - const markdown = JSON.stringify(Markdown.parse({ post: { content } })); - + const markdown = JSON.stringify(Markdown.parse({ post: { content: String.raw`${content}` } })); return { props: { posts, data, markdown, params, previousPost, nextPost } }; } diff --git a/pages/overview/[[...slug]].js b/pages/overview/[[...slug]].js index c181857..559c9ea 100644 --- a/pages/overview/[[...slug]].js +++ b/pages/overview/[[...slug]].js @@ -82,9 +82,8 @@ export default function Overview({ Edit this page on GitHub @@ -365,7 +364,7 @@ export async function getStaticProps({ params }) { "weight" ) || null; - const markdown = JSON.stringify(Markdown.parse({ post: { content } })); + const markdown = JSON.stringify(Markdown.parse({ post: { content: String.raw`${content}` } })); return { props: { posts, data, markdown, params, previousPost, nextPost } }; } diff --git a/pages/reference/[[...slug]].js b/pages/reference/[[...slug]].js index 2829786..7b1fefc 100644 --- a/pages/reference/[[...slug]].js +++ b/pages/reference/[[...slug]].js @@ -81,9 +81,8 @@ export default function GuidePage({ Edit this page on GitHub @@ -130,7 +129,7 @@ export async function getStaticProps({ params }) { "weight" ) || null; - const markdown = JSON.stringify(Markdown.parse({ post: { content } })); + const markdown = JSON.stringify(Markdown.parse({ post: { content: String.raw`${content}` } })); return { props: { posts, data, markdown, params, previousPost, nextPost } }; }