top | item 41818483

(no title)

FrancoisBosun | 1 year ago

This looks very, very interesting! Good work. My only nitpick is the ligatures. I believe pipelining in Elixir uses the |> operator, but the blog post uses a kind of triangle pointing to the right. Due to my previous exposure to Elixir, I guessed that it must have been |>, but if I hadn’t know, then I would be really confused when I tried to write that in my editor to replicate the code.

discuss

order

sbuttgereit|1 year ago

I agree. I use ligatures in my own coding and so to my eyes, the presentation was very natural... but for someone that doesn't/hasn't I think your point is completely correct.

It's better to not use ligatures for publication, such as in this scenario.

(Now that I've said that, I better go check and see if I've made this mistake due to just not thinking about it.... hmm.....)

lawn|1 year ago

I personally like some types of ligatures, but I think it's good to not use them when others should read the code.

mise_en_place|1 year ago

100% agree, it's just jarring to anyone who's developed in Elixir before. It's just like dquote characters on MacOS ("smart quotes")

LorenzoGood|1 year ago

I, as a new elixir user, was personally confused by this exact thing as well.

carrja99|1 year ago

A lot of folks configure their editor to render |> as a rotated triangle.

Kamq|1 year ago

Sure, but putting it in a code sample is similar to putting opening/closing quotes in a code sample instead of "

It makes it harder for people to copy and paste and play with.

brightball|1 year ago

There is some editor plugin that converts it visually to a triangle. I have seen other people use it.

lvass|1 year ago

prettify-symbols-mode in Emacs.