Bump MDX to v2

This commit is contained in:
Kevin Kandlbinder 2022-08-18 22:48:30 +00:00
parent 0b5211a08f
commit e82547e417
6 changed files with 1072 additions and 1214 deletions

View file

@ -42,6 +42,9 @@ exports.createPages = async ({ actions, graphql, reporter }) => {
language
published(formatString: "YYYY/MM")
}
internal {
contentFilePath
}
}
}
}
@ -147,7 +150,7 @@ exports.createPages = async ({ actions, graphql, reporter }) => {
}/${node.childMdx.frontmatter.published}/${
node.childMdx.frontmatter.url
}`,
component: blogTemplate,
component: `${blogTemplate}?__contentFilePath=${node.childMdx.internal.contentFilePath}`,
context: {
mdxId: node.childMdx.id,
lang: node.childMdx.frontmatter.language,