6
sjwsjwsjw
24h

javascript is a dogshit language

typescript makes a valiant attempt to make it better but it's contrived on top of a rocky foundation so it can't quite get there unfortunately

yes i am trash at programming and appreciate strongly typed languages for any heavy duty work, in most cases those languages designed for it from the ground up, don't feel as frustrating to deal with

Comments
  • 3
    Languages as easy as python and js makes you always change it all the time. You don't do that with C or smth. You reason longer. But I think such languages are actually genius.
  • 2
    @retoor I like dynamic languages until I don't. Usually requirements issues are the don't.
  • 4
    Kinda unrelated, but I have a simple take on _strongly_ typed which comes from a C vs C++ perspective: having to explicitly state that I want to interpret this void* as char* sounds good on paper but after doing it for the millionth time I'm like bruh, it's just a number.

    Only more text in the end, which doesn't make the code clearer IMHO. If the types are incompatible (can't interpret one as the other) then casting explicitly doesn't make a difference, so where does that leave us exactly.

    -fpermissive -w also known as live dangerously or alternatively towering defecation upon the C++ standard, give me classes and shut the fuck up, I ain't using any other features. malloc 4 life.

    This message will now this->~typeof(*this) {*(0xDEADBEEF);}
  • 0
    Have you tried Flow? it's amazin
  • 0
    Javascript/Typescript is not bad.

    Definitely a skill issue.
  • 0
    As my name suggests, I am a fan of JS. One thing that people don't always talk about is how the language is regulated by an actual standards body and new features in the language are added in stages by the TC39. They are carefully studied such that they will not break existing syntax or prevent future progress. They even consider existing frameworks and projects in production.

    Even if you don't care about that I think we can all agree you can do some pretty cool shit with it.

    Example: Capitalize every word in a sentence.

    'this is a sentence.'.split(' ').map(w => w.split('').map((c, i) => !i ? c.toUpperCase() : c).join('')).join(' ');

    // 'This Is A Sentence.'

    I banged this out in about 40 seconds and that's with an injured wrist, didn't backspace once and got it right on the 1st try.

    Go do that in literally any other language.
  • 3
    The issue is already in the name. We were supposed to write scripts (!) with it, not fully blown applications. The cancer that grew ontop of JS is mind-blowing. Back then it was just you and the JS between two script tags, now you need to know a gazillion of webpacks and linters and frameworks and Ecmascripts and build targets and runtimes !
Add Comment