JonyEpsilon / gorilla-repl

A rich REPL for Clojure in the notebook style.
http://gorilla-repl.org
MIT License
887 stars 104 forks source link

Table support in Markdown sessions #131

Closed mmower closed 10 years ago

mmower commented 10 years ago

Jony I am really enjoying using Gorilla-repl. I watched your notebooks video and I agree there is something powerful here. I'm building an app and using the notebook approach to drive it. The notes are not comments, they're signposts I'm using as I think about/explore different ways of doing things. I absolutely would not leave these as comments in code. [Are you on IM or IRC btw?]

Anyway so something I'd like would be support for tables in markdown. The classic approach is to use <table> tags but that's a bit rubbish and there's syntax floating around using |....|....| to delimit columns that works pretty well, e.g.

http://www.tablesgenerator.com/markdown_tables

Not sure which markdown processor you're using but in my probing it doesn't appear to support them out of the box. Or am I doing it wrong?

m/

JonyEpsilon commented 10 years ago

Yes, table syntax would be nice!

At the moment it's using the Pagedown markdown processor, as used by SO. And as far as I can tell, it doesn't support table syntax.

So, I think it would probably require switching to a different js markdown processor. Shouldn't be too difficult.

jaredly commented 10 years ago

marked supports tables, and a bunch more besides

JonyEpsilon commented 10 years ago

Thanks, that's very useful. I'll take a look at it. Was also thinking to take a look at the "Common markdown" parser that's been released recently.

JonyEpsilon commented 10 years ago

Turns out CommonMark, as it's now called, doesn't include tables yet. Go with marked, which works a treat.