Skip to content

marp-cli error when using markdown-it-graphiz #434

Answered by yhatt
alanlivio asked this question in Q&A
Discussion options

You must be logged in to vote

A (probably not maintained) markdown-it plugin markdown-it-graphviz you are trying to use is broken: aiyoudiao/markdown-it-graphviz#2 (Chinese)

It tries to load a script written in ES Module ./common/viz.es-changed.js from CommonJS script index.js, but Node.js cannot import ESM script from CJS through require().

In regards to this, there is no way to do in user-side. Try another markdown-it plugin that supports graphviz correctly.

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@alanlivio
Comment options

@yhatt
Comment options

Answer selected by alanlivio
@alanlivio
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
duplicate This issue or pull request already exists
2 participants