Live data from Hacker News

Reach for Markdown, not LaTeX

blog.jez.io

141–150 of 184 posts

Re: Reach for Markdown, not LaTeX

#141

Earlier quoted context omitted.

Fair enough. My wife uses Adobe tools for typesetting, she is a professional (she pays $100/month for her CS subscription, however). I'm not a professional, I've looked at the amount of effort needed to refine output in these tools and they make LaTeX look usable...

I find that in most cases InDesign takes an order of magnitude less time/effort and dramatically less frustration to get a particular careful output than MS Word, LaTeX, or other commonly available tools. Your wife probably has difficult requirements and exacting quality standards, and could likely get output with quality equivalent to common documents prepared using amateur/automatic tools in a much shorter time, if…

If you're doing many one-off designs, I'm sure something like InDesign is faster than TeX. However, if you are producing similar-looking documents, the effort of writing your own LaTeX class is relatively low.

There's also other advantage to using LaTeX, and that is the flexibility that comes with macros. Need to change some notation mid-way through your writing? It's trivial if you've used macros. Need to simplify some commonly used pattern? Define a new macro!

Each tool has their place. Except Word, Word just sucks! (j/k, Word is brilliant when doing collaborative edits with non tech-savvy people, the track changes functionality is great, and not easy to replicate in other environments)

Re: Reach for Markdown, not LaTeX

#142

Earlier quoted context omitted.

I wrote mine in plain LaTeX, never had an issue with it. Regarding code, you can use the listings package (\lstincludelisting) to include source code files directly. I fail to see the interest in having a bastardized, not quite TeX, not quite MD file (unless you're using something like Org, of course, and using its other functionalities). Regarding having unicode for the maths, how did you deal with symbols that need…

I just make the symbols shortcuts for the commands. So for instance ∑_{0≤n≤k}n² expands to \sum_{0\le n\le k} n^2.

Do you have a library of these substitutions available? Sounds like it could be useful.

Re: Reach for Markdown, not LaTeX

#143
post #120

Pandoc is really awesome. Even mathematics papers can be written in (mostly) markdown, and then converted to latex before compiling to PDF. For mathematics I would also recommend using Unicode symbols in place of LaTeX commands, which makes the source even more readable. For instance $∏_{x∈X} ∑_{y∈Y} Ψ(x,y) → ∑_{f : X → Y} ∏_{x∈Y} Ψ(x,y)$ instead of $\prod_{x \in X} \sum_{y \in Y} \Psi(x,y) \to \sum_{f : X \to Y} \pr…

You can avoid having to declare each character separately if you use the unicode-math package: https://github.com/wspr/unicode-math . I suggest you try it; it's life-changing for e.g. general relativity stuff where there are a lot of Greek letters being thrown around!

That looks really interesting! Thanks for sharing!

Re: Reach for Markdown, not LaTeX

#144
post #130

I don't get it. Say I already know that I'll need some formulae in my document. Then the use case here seems to be, essentially, that I can write # Section Name instead of \section{Section Name} and that I can write *important stuff* instead of \emph{important stuff}. I can see that the markdown version is a little nicer on the eyes and keyboard, but only by a small margin. Now, if I write a document in latex I need…

> Latex is a beast, but there are no serious alternatives to typeset formulae.

People keep repeating this like it's true, but MS Word has had an excellent formula editor for a decade now (the one they shipped before Word 2007 was terribly shitty though).

It's wysiwyg (which is fantastic if you're editing a big formula), it supports all math notation I've ever needed, and it has surprisingly decent UX. It even supports LaTeX-like input, eg if you type e^2 it gets autocorrected to e².

This makes entering formulas as fast, if not faster, than LaTeX and editing formulas an order of magnitude easier because you don't need to re-parse that backslash-curly-mess that you entered a week ago. Just point and click and edit.

Re: Reach for Markdown, not LaTeX

#145
post #130

I don't get it. Say I already know that I'll need some formulae in my document. Then the use case here seems to be, essentially, that I can write # Section Name instead of \section{Section Name} and that I can write *important stuff* instead of \emph{important stuff}. I can see that the markdown version is a little nicer on the eyes and keyboard, but only by a small margin. Now, if I write a document in latex I need…

> Latex is a beast, but there are no serious alternatives to typeset formulae. People keep repeating this like it's true, but MS Word has had an excellent formula editor for a decade now (the one they shipped before Word 2007 was terribly shitty though). It's wysiwyg (which is fantastic if you're editing a big formula), it supports all math notation I've ever needed, and it has surprisingly decent UX. It even support…

It's nowhere near as nice in my, and lots of other people's, opinion. Just because people don't like it doesn't mean they haven't used it. Also, word's actual typesetting can't touch latex. I wouldn't want to use word for anything, let alone something that requires a large equation.

Re: Reach for Markdown, not LaTeX

#146
post #134

Earlier quoted context omitted.

Pandoc is awesome for things like tables or code blocks. Here is a table in pandoc markdown: | Header 1 | header 2 | |-|-| | Column 1 | Column 2 | Which is easy to write via emacs mode/vim plugin. Similar for code blocks. Plus this is extendable, I frequently use an extension that transforms DOT syntax into embedded graphs.

Thing is, if you're already looking to use e.g., Emacs, you'll be better off using org-mode instead of markdown. Same lightness of syntax, tens of times the functionality (including much better tables, which you can use directly from a TeX document, as well, via radio tables). Editing ascii tables with no editor support is painful. There's also some org functionality in vim plugins, though I've never used them, so I…

> if you're already looking to use e.g., Emacs, you'll be better off using org-mode

I find that you should use org only if you use Emacs. Vim plugins for Org are very limited, and this is even more true for other editors.

Judging a technology only for its technical merits is unproductive. Markdown has "won", it's everywhere and everyone can learn to use it. Those are damn powerful advantages.

Using Markdown, I gain the ability to read and write on a smartphone or tablet in my phone or tablet, which for some notes is extremely convenient. Many times being able to access my notes on philosophy from my phone during a bus commute allowed me to develop and write down a thought, which would have been a pain to do with other technologies. Of course I could have done the same with other options, but this ubiquitous convenience and effortlessness is great.

What I'd love to see is a way to transition easy-to-write-everywhere to more powerful type-setting easily when needed. May be combining Markdown and Latex? Or converting Markdown to Latex before publishing?

I'm sure this exists already; I just haven't needed it enough yet :)

Re: Reach for Markdown, not LaTeX

#147
post #26

Author here! I'd like to take a second to point out that the audience I had in mind when writing this article was mostly my fellow classmates in college. In school we were hastily introduced to LaTeX freshman year and were required to typeset our homeworks before submission. The point of the article isn't "you should never use LaTeX" but rather "hey, there's this other, simpler tool that you might like better!" plus…

Thank you for the clarification. This should be top posted to avoid a lot of the posts that have already occurred. LaTeX is far more encompassing than Markdown will ever be.

Re: Reach for Markdown, not LaTeX

#148

Earlier quoted context omitted.

Have you ever tried to typeset a complex document with side bars, figures, multi-part figures, figures that contain math (not just images), and layouts that take a lot of tweaking to get just right? I can imagine doing that in Pandoc Markdown, but only with extensive use of raw LaTeX code. Most of the above doesn't have a direct equivalent even in richer Markdown dialects like Pandoc.

Ah, thanks for educating me. I pity anyone who has to work within the constraints of print in 2018. To me, hypertext that adapts to the user's device and needs (e.g. rendering at a different font size and reflowing appropriately, or rendering through non-visual means like speech and braille) is the only way to go these days.

It's harder to make fine adjustments, such as those made by the microtype latex package.

Re: Reach for Markdown, not LaTeX

#149
post #68

Earlier quoted context omitted.

Do you think legal writing falls into this category?

I have a dream where someone writes a processor that will allow the writer to bang out some Markdown-ish plaintext and turn it into a p&a with automatically generated Table of Contents, Table of Authorities, caption, and pleading paper. Call it LexDown or something even less mellifluous and free millions from the tyranny of Word style sheets forever.

You may be interested in Markua https://leanpub.com/markua/read
Post reply on HN