Markdown chart library

If i wanted to make this work Kirby, how would I go about it? Is it possible?

It’s a charting library that will generate charts from specially crafted Markdown.


Since you need markdown formatted text in the browser, you would have to prevent markdown rendering on the server for those parts of the text that contain your chart definitions. For example, if you put your markdown code within a div…

But from what i can tell in the Markvis documentation, its an extension to Mardown-it. What is Kirby using to parse Markdown? Im sure i read somewhere that it can be swapped out for another parser somehow (unless i was dreaming).

If Kirby can be made to use Markdown-it, then this chart extension could be added as a plugin… am i still dreaming?


But if you swap parsedown for markdown-it on the server, that doesn’t help you any in the browser? I’m not saying it can’t be done, you just have to prevent markdown rendering for those bits on the server.

ahhhhh i seeee now what you mean. I thought Markvis created a chart by parsing the Markdown server side. But u think its happening client side? Shame, that could have been good.

You can also do it on the server in a node.js environment, I think. But that’s beyond my skills… However, I think that if you put the naked markdown into a div with a class, you could call the contents of that div within this bit of code

  your makrdown content
`, {
  d3,    // in browser environment
  d3node // in node environment

in the browser.

With enough coffee, anything is possible :slight_smile:

Need the coffee to learn Vue…

I feel your pain. Im learning PHP and Angular.