News for hackers. Stuff that matters.
Re:When Rust Makes Sense, or The State of Typed Languages by sagichmal on Monday September 28, 2015 @04:05AM (#10289355)
Re:When Rust Makes Sense, or The State of Typed Languages by walrus on Monday September 28, 2015 @04:33AM (#10289425)
Do you have HTTPS Everywhere installed or JavaScript disabled? The site tries to load a Markdown-rendering JS library over HTTP, so if you visit https://m50d.github.io/ instead of http://m50d.github.io/, your browser won't render the Markdown.
Re:When Rust Makes Sense, or The State of Typed Languages by emn13 on Monday September 28, 2015 @05:39AM (#10289572)
I think it's sort of weird how people have latched on to markdown. Minimalist html is hardly any wordier than markdown, and at least that works everywhere, and works the same everywhere (unlike xyz-flavored markdown of the month), and it allows an escape hatch into complex layout when you really need it.
Re:When Rust Makes Sense, or The State of Typed Languages by d_theorist on Monday September 28, 2015 @06:10AM (#10289650)
Markdown is fine, but I can't understand why you would want to render it in the browser. Why get the client to do the work with every request? Just render it once on the backend and deliver the html.
Re:When Rust Makes Sense, or The State of Typed Languages by emn13 on Monday September 28, 2015 @06:40AM (#10289718)
Sure, it's "fine" - it's just unnecessary, less portable, less future-proof, and more complex to render (as this article demonstrates). What's the point? Why opt for that complexity when you don't need to? Just to save a very low percentage of key-strokes? That strikes me as being penny-wise & pound foolish. And much as most text is fairly bare-bones, sometimes you do want extra layout control - and then markdown is really in your way.
Re:When Rust Makes Sense, or The State of Typed Languages by d_theorist on Monday September 28, 2015 @06:57AM (#10289766)
I don't see why it's either less portable or less future proof.

It's a different markup. One that many people find easier and more natural to write. Of course, different people have different opinions on that.

For people who find writing and reading markdown nicer than HTML it makes sense to use markdown as the base format that you write everything in, and then convert to different formats as needed (html, pdf, whatever).

For you, HTML may play that role. Personally I find HTML ugly to read and write.

Re:When Rust Makes Sense, or The State of Typed Languages by emn13 on Monday September 28, 2015 @05:16PM (#10293262)
I agree that markup is easier to write - it's shorter. And typical html is much messier. But if you wrote html the way you did markdown the difference is much smaller. In fact - look at the OP's text. That article in html would be barely longer.

To summarize: markup is better to read+write. But the difference is almost zero. Anything other than trivial markup is a mess; exceptional layout often impossible (and I value the ability to creatively use layout to get my point across). It doesn't support wysiwym editing (very well). It isn't trivially statically hostable - and if you try it's fragile and flashes uglily. Many flavors exist that are slightly different.

I prefer flexibility, consistency and simplicity over micro-optimizing source readability.

Re:When Rust Makes Sense, or The State of Typed Languages by lmm on Monday September 28, 2015 @07:58AM (#10289947)
My blog originally lived on fully static hosting. When I moved to github I made minimal changes.

I also like the idea that the "source" is right there on the page rather than a separate "API" - the dream of XHTML+XSLT. When I originally set it up I wanted the page to be readable using Telnet - which I think it is, more so than one rendered on the server would be. I couldn't tell you now why that seemed important though.

Re:When Rust Makes Sense, or The State of Typed Languages by sagichmal on Monday September 28, 2015 @05:32PM (#10293364)
OK, that explains it. But it's crazy, in my opinion, to use JavaScript for this purpose.
Re:When Rust Makes Sense, or The State of Typed Languages by d_theorist on Monday September 28, 2015 @06:05AM (#10289637)
Thanks.