9 ms·
Show HN: Excel-like table editing for Markdown
- fortylove 7y agoVery nice! It would be really cool if you can do some simple math too, like =sum(...), and have it update the markdown for you. I like it!
- zelphirkalt 7y agoYou mean, like in org mode tables?
- fortylove 7y agoI've seen reference to org mode quite a few times now. I will have to check it out.
- bloopernova 7y agoIt's a massive, huge, enormous thing. It will seem daunting at first. Especially if you have to learn Emacs as you go. https://orgmode.org/worg/org-tutorials/org4beginners.html https://orgmode.org/worg/org-tutorials/org4beginners.html That tutorial seems pretty good, it starts from the absolute beginning.
- jakew 7y ago@fortylove That's a really good idea. I'm going to add simple math in the table editor.
- turbinerneiter 7y agoI wrote this filter for Pandoc once that allowed you to execute Python from within cells and replace the cell content with the results. It also used row names as variable names. Sadly, I can't find the markdown file that actually uses it and I also can't remember how it worked. But the point is: you can do it (badly, but working) in ~100 of Python code as a plugin for Pandoc.
- tomerbd 7y agohttps://typora.io/ https://typora.io/ is also excellent for that
- komatsu 7y agohttps://support.typora.io/Table-Editing/ https://support.typora.io/Table-Editing/
- dejj 7y agoLooks so nice. Too bad their Debian repo https://typora.io/linux/ https://typora.io/linux/ has gone away. Are the sources published somewhere? Seems like Github only has the website and some themes.
- wiradikusuma 7y ago@jakew can your product work as front-end for Joplin?
- jakew 7y agoNot sure about the notes format of Joplin. If it's Markdown files, then yes, you can open any Markdown folders in Document Node. However, many users are using Document Node for notes taking, as it provides the most flexible way to arrange your content simply in folders.
- szhu 7y agoPossibly relevant for those looking for easier ways to create Markdown tables: A few years ago, I wrote a spec for Markdown tables using a subset of YAML -- no GUI required for authoring. Curious what HN thinks of it: https://github.com/IFTTT/tablerize https://github.com/IFTTT/tablerize
- vanderZwan 7y agoI like it! Reminds me a bit of comma separated trees: https://observablehq.com/@mbostock/comma-separated-tree https://observablehq.com/@mbostock/comma-separated-tree
- sadness2 7y agoI'd adopt this immediately if it could integrate with editors like vscode
- cstuder 7y agoWhile we wait for somebody else to implement this, here is a first step: Install the `prettier` extension and turn on autoformat for markdown. It makes entering tables much easier and the tables more readable.
- sulami 7y agoI’ll be that one person: org-mode already does tables with formulas and all[1], if you’re interested in text-based spreadsheets [1]: https://orgmode.org/manual/Tables.html https://orgmode.org/manual/Tables.html
- ggm 7y agoRecent convert but org mode columnar sums still look a bit tricky. M-x org-md-export-to-markdown is my friend!
- zelphirkalt 7y agoSums of a whole column in org mode tables is among the simples formulas you can write for tables. Just call the sum function (vsum?), enter the start cell and end cell, and where you want to put the result. That's it. Except that it is text only, I don't see what's more difficult, than entering a formula in a GUI spreadsheet app.
- ggm 7y agoThe examples on the web have weird markup
- zelphirkalt 7y agoI should write some examples for tables and put them in a repo somewhere. You are right, sometimes the examples require a bit of trying and a lot of thinking, before one can apply them. That should not be. However, once you figure it out, it is amazing ;)
- ggm 7y agoPlease do!
- abdullahkhalids 7y agoI used org-mode tables to tabulate student grades for a course I was teaching last semester. Summing single columns was okay. But I needed to drop selected assignments (had a column with 1s and 0s). And then had to figure out the percentage marks each student had in the assignment component. It was honestly a huge pain. I could have written the formulas for this in under 15 min on a regular spreadsheet software. With org-mode I spent hours trying to figure it out. In the end I had a hacky solution that I don't want to use again.
- deleted 7y ago[deleted]
- lifeisstillgood 7y agoHmmm, it's at this point I really want to improve the docutils/sphinx table handling...
- Haow 7y agoHope the markdown table can support some high-level options like function, I'll love it。
- jakew 7y agoI will add simple functions in the next version. Specifically in two or three weeks. I promise.
- laumars 7y agoYour demo doesn't show any cell padding. Is this the case for the final product? If so, is that something you're working on? I'm not a huge fan of tables in markdown but if they're necessary then it should at least be readable in clear text and without padding it's not. eg with padding: | which | column | is | the | value | foo | in | ? | |-------|--------|-----|-----|-------|-----|----|---| | | | foo | | | | | | vs without padding | which | column | is | the | value | foo | in | ? | |-------|--------|-----|-----|-------|-----|----|---| | | | foo | | | | | |
- jakew 7y agoI have thought about this. Padding works when the text in a cell is not too long. When cell texts are arbitrary long, "padding" doesn't make sense any more. Document Node is not just a pure Markdown editor, it has a beautiful HTML5 preview area, where you can see your tables in a perfect format. You can define your own styles using CSS, although we have 11 preview styles built-in. Having said that, I think it's a good idea to give the users the option to enable padding. I will add that option in a later version. There never be a final product for us and stop there, we will keep improving it and roll new versions frequently.
- laumars 7y ago> I have thought about this. Padding works when the text in a cell is not too long. When cell texts are arbitrary long, "padding" doesn't make sense any more. I do understand your point but you could also argue that's when you need padding the most because it becomes infinitely harder to visually parse the raw text. I like your idea for giving people the option though. > Document Node is not just a pure Markdown editor, it has a beautiful HTML5 preview area, where you can see your tables in a perfect format. Document Node is a nicely polished product but it's worth remembering that the point of markdown is that it's still readable without needing a viewer that supports rich formatting. For example it should be just as readable in the terminal as it is in a HTML5 container (this is one of the reasons I don't really like tables in markdown but that ship has already sailed). Unfortunately not everyone will be using Document Node to view their markdown.
- escobook 7y agoThis is very great articles. Keep it up. I visited your website, Its amazing experience for me. Hire Female girls for a cheerful evening. https://escobook.com/call-girls/ https://escobook.com/call-girls/
- kristiandupont 7y agoOh, this is interesting! I created a webpack loader for markdown files because I use tables to store config and test data (https://www.npmjs.com/package/mdconf-loader https://www.npmjs.com/package/mdconf-loader) -- formatting in vscode already helps, but this will take it to another level.
- cryptos 7y agoAlthough it looks nice, tables and Markdown are not a good fit. The syntax for tables in Markdown is broken by design! AsciiDoc got it right: https://asciidoctor.org/docs/asciidoc-syntax-quick-reference/#tables https://asciidoctor.org/docs/asciidoc-syntax-quick-reference... You can even have formatted source code in AsciiDoc table cells. Try this with Markdown ...
- jamesrcole 7y ago> The syntax for tables in Markdown is broken by design! can you elaborate?
- cryptos 7y agoThe syntax simulates the visual representation of tables, but that doesn't scale for larger tables with many columns and/or large columns with a lot of content. Another downside is that you can not use markup, like bullet lists or source code formatting, in table cells. Markdown tables are overly simplistic.
- laumars 7y agoThat's because the point of markdown is to be an overly simplistic styling convention that reads just as cleanly in clear text (eg on the terminal) as it does in formatted renderers. Tables weren't even part of the original design of markdown. In fact there's a lot of stuff that Github and others have bolted onto markdown. The real problem with markdown is that now it has now reached the kind of critical mass where people start using it everywhere and reaching for it even when it doesn't make sense simply because it's the first thing that pops into peoples head. So, in my personal opinion, if you start needing the kind of design sugar as formatted cells then you really should be using any one of the plethora of other document formats out there because you're requirement no longer fits around the core principle of markdown. A great many of which can still be composed in a text editor and some of which are still relatively easy for a human to parse. [edit] Getting downvoted on this so I'll provide some citations: > "[Markdown's] key design goal is readability – that the language be readable as-is, without looking like it has been marked up with tags or formatting instructions" Source: https://en.wikipedia.org/wiki/Markdown#History https://en.wikipedia.org/wiki/Markdown#History (Wikipedia, Markdown history) > "A Markdown-formatted document should be publishable as-is, as plain text, without looking like it’s been marked up with tags or formatting instructions. While Markdown’s syntax has been influenced by several existing text-to-HTML filters — including Setext, atx, Textile, reStructuredText, Grutatext, and EtText — the single biggest source of inspiration for Markdown’s syntax is the format of plain text email." Source: https://daringfireball.net/projects/markdown/syntax https://daringfireball.net/projects/markdown/syntax (John Gruber, one of the co-creators of markdown) > Markup offers an alternative means to encode this signaling information by overloading certain graphic characters (see, e.g., [ISO646]) with additional meanings. Therefore, markup languages allow for annotating a document in a syntactically distinguishable way from the text, while keeping the annotations printable. Source: https://tools.ietf.org/html/rfc7763 https://tools.ietf.org/html/rfc7763 (original RFC)
- majkinetor 7y agoEditor extensions go along the way instead propriatery BS for stuff that should be foss in 2020. Example - with VSCode you have Markdown all in one [1] Just do "Format Current Table" and thats it, see a picture [2]. Along with column editing and other advanced editor features there is simply no need for anything else, such as excel like GUI. When I see "pricing" on markdown editor, I really get nausea [1] https://marketplace.visualstudio.com/items?itemName=yzhang.markdown-all-in-one https://marketplace.visualstudio.com/items?itemName=yzhang.m... [2] https://github.com/yzhang-gh/vscode-markdown/raw/master/images/gifs/table-formatter.gif https://github.com/yzhang-gh/vscode-markdown/raw/master/imag...
- leppr 7y agoThe Free in FOSS is not for free as in free beer [1]. If you get nausea at people wanting to be compensated for their work, you have a problem. [1]: https://www.gnu.org/philosophy/floss-and-foss.en.html https://www.gnu.org/philosophy/floss-and-foss.en.html
- majkinetor 7y agoNah, I get nausea at people wanting to be compensated for reinventing the weel.
- tanseydavid 7y agoHave you figured out a way to print rendered Markdown from VSCode? Or even just print rendered version to PDF? The lack of this feature makes Markdown in VSCode a no-go for me.
- majkinetor 7y agoYeah. All in one markdown has PDF export. I use it all the time.
- neves 7y agoLatex failed for me in table generation. It is great to write without concerns about formatting, but it is really hard to create a table in Latex. Hope Markdown solves this problem, but it isn't easy to solve the usability issues.
- auxym 7y agoWriting raw latex sort of sucks for more than tables. You need a specialized editor/plugin for your favorite editor. I like LyX a lot!
- fiatjaf 7y agoSee also https://stevecat.net/table-magic/ https://stevecat.net/table-magic/ for quickly editing and translating tables between CSV/TSV/HTML/Markdown/SQL.
- james_smith_007 7y agoI don't need a software that require me to sign in before use.
- deleted 7y ago[deleted]
- begemotz 7y agoMy table needs are rather simple but I use: http://www.tablesgenerator.com/markdown_tables http://www.tablesgenerator.com/markdown_tables
- stadeschuldt 7y agoI have recently bought an app for macOS that helped me handling tables in markdown: https://tableflipapp.com/ https://tableflipapp.com/ It does one thing and it does it well.
- saadalem 7y agoWhat do you think of Markdown forms ?
- jakew 7y agoI haven't evaluated how important is that for daily uses. :) I saw there was a discussion in CommonMark's forum.
- m3at 7y agoThere is also a vim plug-in that do much of the same, even handling formulas (!): https://github.com/dhruvasagar/vim-table-mode/blob/master/README.md https://github.com/dhruvasagar/vim-table-mode/blob/master/RE... Personally I prefer to keep my markdowns simple, as it was explicitly designed to be a simple markup readable in raw form. Often the constraints of simplicity force me to think deeper about what I'm trying to explain so as to fit the format; limitations can be a strength.
- deleted 7y ago[deleted]
- anderspitman 7y agoOT - has anyone ever managed to make a decent text-based spreadsheet file format?
- acidburnNSA 7y agoLooks really slick. Thanks for the contribution! I don't know if this is sacrilege or not here but I really like reStructuredText's list-table directive [1] for this kind of thing. It provides a text-friendly editable representation that renders to a nice table. There's a CSV-based table directive also (scroll up one in the link). .. list-table:: Frozen Delights! :widths: 15 10 30 :header-rows: 1 * - Treat - Quantity - Description * - Albatross - 2.99 - On a stick! * - Crunchy Frog - 1.49 - If we took the bones out, it wouldn't be crunchy, now would it? * - Gannet Ripple - 1.99 - On a stick! I like Markdown a lot for simple things like notes and readmes. When I write technical documentation and when I wrote my e-book, RST had the extended feature set I needed. [1] https://docutils.sourceforge.io/docs/ref/rst/directives.html#list-table https://docutils.sourceforge.io/docs/ref/rst/directives.html...
- crooked-v 7y agoWhen it comes to 'text-friendly' I far prefer nicely formatted MMD tables... | Treat | Quantity | Description | | :------------ | :-------- | :-------------------------------------------------------------- | | Albatross | 2.99 | On a stick! | | Crunchy Frog | 1.49 | If we took the bones out, it wouldn't be crunchy, now would it? | | Gannet Ripple | 1.99 | On a stick! | [Frozen Delights!] ...despite the comparative hassle in editing them. It's just so much more readable at a glance later.
- faywong 7y agowhat gui library does this app use?It seems cool.
- jakew 7y agoThanks for letting us know you think it's cool. :) The GUI library is QT. But not ordinary Qt, we did lots of customization. A large amount of time invested in polishing it.
- faywong 7y agoThanks for clarify. The tiny version of Qt you polished is the key weapon behind the product. I always pay attention to GUI/render related projects.
- donatj 7y agoI built a little tool a while ago that converts CSV/TSV to Markdown. I use it mostly o convert MySQL EXPLAIN's to Markdown for pull requests. https://donatstudios.com/CsvToMarkdownTable https://donatstudios.com/CsvToMarkdownTable
- hnal943 7y agoNeeding tools to edit markdown seems to defeat the point, doesn't it?
- xixixao 7y agoThis is good but it'd be even better inline, the same way Bear both displays markdown and shows the markers, you could imagine that the "Excell" UI could be embedded inside the plain text editor.
- jakew 7y agoThat's a very interesting idea. Something worth having a research. I've taken notes for it. Thanks.
- josh3736 7y agoAfter simply opening a md file, I found that Document Node corrupted it (linebreaks disappeared and content replaced with garbage characters). Fortunately, the file was in a git repo, so I was able to revert and no harm done, but that does not exactly inspire confidence...
- jakew 7y agoThanks for letting us know about the issue. Was your document in a different encoding rather than UTF-8? We will find it out and fix it shortly.
- josh3736 7y agoDocument in question is https://github.com/useful-bytes/netsleuth/blob/v1.0.9/README.md https://github.com/useful-bytes/netsleuth/blob/v1.0.9/README... It's UTF-8 with unix line endings.