Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MDX Markdown Support #12902

Open
drush opened this issue Oct 2, 2024 · 1 comment
Open

MDX Markdown Support #12902

drush opened this issue Oct 2, 2024 · 1 comment
Labels
Milestone

Comments

@drush
Copy link

drush commented Oct 2, 2024

MDX has matured quite a bit since this was discussed previously on the forum.

  • Now at version 3
  • Supports YAML or Native frontmatter
  • Has a CLI

It is also supported by many of the newer SSGs such as Astro, Next etc. Supporting MDX is now table stakes for Hugo to stay a competitive option.

This also makes it very easy to build pages with interactive components (charts, forms, etc).

@bep bep removed the NeedsTriage label Oct 3, 2024
@bep bep added this to the Unscheduled milestone Oct 3, 2024
@bep
Copy link
Member

bep commented Oct 3, 2024

It would be good if you could add some lines about how you would propose to implement this.

Supporting MDX is now table stakes for Hugo to stay a competitive option.

I didn't know this was a ... competition? Never mind ...

I have looked at MDX, and to me it looks like a odd construct, and probably a bad fit in Hugo, especially considering that there's no native Go implementation of this (is it?). In my head, Markdown shines for (potentially lots of) content rendered to e.g. HTML. Having Markdown transpiled to JavaScript which then gets rendered to HTML in the browser sounds a little bit off to me, and I think it would be good for Hugo to be a little original in this department. To stay competitive, so to speak :-)

The next Hugo will come with improved support for JS code splitting/bundling/etc., which should make it trivial to add React/JSX/TSX via shortcodes/render hooks, which in my head is a nicer separation of concerns compared to MDX.

But maybe I missed something. The proposal was very brief.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants
@drush @bep and others