jxnblk / mdx-deck

♠️ React MDX-based presentation decks
https://mdx-deck.jxnblk.com
MIT License
11.32k stars 605 forks source link

[gatsby-theme-mdx-deck] Doesn't work when added to an existing Gatsby site #737

Closed jcayzac closed 4 years ago

jcayzac commented 4 years ago

Adding gatsby-theme-mdx-deck 4.1.0 to a boilerplate blog using e.g. @lekoarts/gatsby-theme-minimal-blog produces build errors similar to what was reported in #466 (tho it has nothing to do with layouts).

failed Building production JavaScript and CSS bundles - 9.728s

 ERROR #98123  WEBPACK

Generating JavaScript bundles failed

unknown: Identifier '_frontmatter' has already been declared (61:13)

  59 | MDXContent.isMDXComponent = true;
  60 |
> 61 | export const _frontmatter = {};
     |              ^
  62 |

File: src/pages/404.mdx:61:13

 ERROR  Command failed with exit code 1.

Dependencies:

    "@lekoarts/gatsby-theme-minimal-blog": "^2.3.10",
    "gatsby": "^2.23.18",
    "gatsby-theme-mdx-deck": "^4.1.0",
    "prop-types": "^15.7.2",
    "react": "^16.13.1",
    "react-dom": "^16.13.1"
jcayzac commented 4 years ago

Maybe cause by https://github.com/ChristopherBiscardi/gatsby-mdx/issues/354#issuecomment-482693692

jcayzac commented 4 years ago

Never mind, mdx: false FTW…