Re:Show HN: Making Python one-liner-fit with the new pwk (Py...
by bpicolo on Sunday November 22, 2020 @01:47PM
(#25179862)
We tried that for a while, yeah? https://coffeescript.org/
Re:Show HN: Making Python one-liner-fit with the new pwk (Py...
by mbirth on Sunday November 22, 2020 @03:38PM
(#25180836)
And I loved it. So much more convenient than standard JavaScript.
Re:Show HN: Making Python one-liner-fit with the new pwk (Py...
by mistersys on Sunday November 22, 2020 @08:34PM
(#25182762)
CoffeeScript code bases are the scariest code bases on the planet, the nightmares. To me CoffeeScript inherited all the inconsistencies of JavaScript, then made the syntax inconsistent as well. It least it had optional chaining.
Re:Show HN: Making Python one-liner-fit with the new pwk (Py...
by irjustin on Sunday November 22, 2020 @10:32PM
(#25183332)
It's weird right? I come from Rails and thought CoffeeScript (CS) could make it way more readable, like Python but with cool string interpolations!
But you're absolutely right, it made my code really hard to reason about. I don't know why this is the case but it was always harder to read my own CS than raw JS. I found myself putting blocks into the CS2JS just to read inner workings.
While it made me less verbose and short-term faster, longer term it made me slower.
Re:Show HN: Making Python one-liner-fit with the new pwk (Py...
by pkage on Monday November 23, 2020 @01:01AM
(#25184003)
JavaScript has optional chaining now! https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...
Re:Show HN: Making Python one-liner-fit with the new pwk (Py...
by andybak on Sunday November 22, 2020 @01:52PM
(#25179913)
Oh god. You're right. I'd blotted that out of my memory.
Re:Show HN: Making Python one-liner-fit with the new pwk (Py...
by bobbylarrybobby on Sunday November 22, 2020 @01:45PM
(#25179844)
How would JS with semantic whitespace difference from just auto-indenting a JS file?
Re:Show HN: Making Python one-liner-fit with the new pwk (Py...
by strombofulous on Sunday November 22, 2020 @02:02PM
(#25180013)
Lamdas and first-class functions might make it pretty ugly, I definitely write `func(arg1, arg2, (res) => console.log(res))` from time to time
Re:Show HN: Making Python one-liner-fit with the new pwk (Py...
by andybak on Sunday November 22, 2020 @01:52PM
(#25179918)
It would look nicer.
Re:Show HN: Making Python one-liner-fit with the new pwk (Py...
by OJFord on Sunday November 22, 2020 @02:05PM
(#25180041)
Semantic whitespace looks nicer than non-semantic whitespace?
Re:Show HN: Making Python one-liner-fit with the new pwk (Py...
by andybak on Sunday November 22, 2020 @02:29PM
(#25180262)
No curly braces looks nicer than curly braces.
Re:Show HN: Making Python one-liner-fit with the new pwk (Py...
by pindab0ter on Monday November 23, 2020 @01:51AM
(#25184189)
And that’s just a fact.
I wasn't aware of this. I guess it might silence a few critics.
However I'd be much more interested to try "Javascript with semantic white space"