code-hike / codehike

Build rich content websites with Markdown and React
https://codehike.org
MIT License
4.68k stars 142 forks source link

[highlighter] Should include language dependencies #80

Closed pomber closed 2 years ago

pomber commented 2 years ago

This doesn't work very well:

const code = await highlight({
    code: mdx,
    lang: "mdx",
    theme,
  });

Because 'mdx' depends on 'md' and 'jsx' and so on.

Two potential fixes: