←back to thread

650 points Stratoscope | 1 comments | | HN request time: 0s | source
Show context
psychoslave ◴[] No.43503594[source]
If you are looking for alternative to kebab case to write identifier in programming language which reserve the - (U+002d) as an operator, chances are good you can use · (U+00B7 · MIDDLE DOT), that we use in middot case.

So isMorePleasantToRead, is_more_pleasant_to_read or is·more·pleasant·to·read is up to you.

replies(2): >>43503658 #>>43504170 #
nlitened ◴[] No.43503658[source]
But how pleasant is it to write?
replies(1): >>43504061 #
1. psychoslave ◴[] No.43504061[source]
On the bépo layout that I use, extremely well, as it sits between ’ (U+2019 ’ RIGHT SINGLE QUOTATION MARK) and ‑ (U+2011 ‑ NON-BREAKING HYPHEN), each being generated by altgr+shift and x . and k (which are all on the opposite side of the keyboard compared to altgr key).

At least from the point of view of digital gymnastic, it’s not really any worst than camel or snake cases, though direct access to dash could be said to give a small facilitation for input in kebab case.

So it really depends on the keyboard layout used (or whatever input device facility is used). What’s you favorite input method lately? Does it really doesn’t provide a convenient way to input more than ASCII visible glyphs?

Plus, let’s be honest, identifiers are generally written in full expanse only once, then autocompletion is going to do it for us. And we all know we spend more time reading identifiers than declaring new ones.