1
1
mirror of https://github.com/jxnblk/mdx-deck.git synced 2024-11-29 13:58:02 +03:00

Rename internal layout const

This commit is contained in:
Brent Jackson 2019-04-05 19:54:22 -04:00
parent 0b6a7eda21
commit b263f1a8ce

View File

@ -30,12 +30,12 @@ const toJSX = (node, parent, opts = {}) => {
return [
'(props => {',
` const Layout = ${layout ? layout : '"div"'}`,
' return <Layout',
` const __MDXDECK_LAYOUT__ = ${layout ? layout : '"div"'}`,
' return <__MDXDECK_LAYOUT__',
' name="wrapper"',
' components={props.components}>',
' ' + jsxNodes.map(child => toJSX(child, node)).join('\n '),
' </Layout>',
' </__MDXDECK_LAYOUT__>',
'})',
]
.filter(Boolean)