No offence

You are viewing a single thread.
View all comments View context
22 points

Because it’s inescapable. Web development is by far the most common type of programming work and even if you’re a backend developer you tend to have to touch javascript at some point, so everyone knows the pain of javascript’s foot guns and javascript has a lot.

The fact that it’s mandatory to do your work invokes bitterness in people. For backend, you can kind of switch around until you find a language you like. For frontend, it’s javascript or nothing at all.

Javascript as a language is very out of sync with other commonly used languages. Its footguns are very easy to run into. As a result you have a lot of rituals around just not shooting yourself in the foot. The rituals, libraries, and frameworks around avoiding Javascript’s foot guns have been very shifting and changing. Of course, because the javascript ecosystem changes far faster than other languages, there are a lot of rakes for developers to step on to add to the naturally existing foot guns.

Javascript as a language probably shouldn’t be the sole language of the internet for a variety of reasons. It’s a very hateable language because of how easy it is for newbies to make new terrible code and how common it is. Until something like WASM takes off, the downpour of hate for javascript will continue.

permalink
report
parent
reply
3 points
*

Javascript as a language is very out of sync with other commonly used languages.

How so? Moving back and forth between Typescript and C# / Java is pretty natural imho, as long as you understand the compiled vs interpreted differences.

permalink
report
parent
reply
2 points

In my experience (Javascript and PHP, which both have plenty of footguns), these pitfalls can be avoided by using good practices.

Just because they are dynamically typed doesn’t mean you have to use dynamic typing. Don’t type switch your variables.

Just because you don’t have to use brackets in a certain scenario doesn’t mean you can’t. Use them as needed for clarity.

That kind of thing.

permalink
report
parent
reply

Programmer Humor

!programmerhumor@lemmy.ml

Create post

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

  • Posts must be relevant to programming, programmers, or computer science.
  • No NSFW content.
  • Jokes must be in good taste. No hate speech, bigotry, etc.

Community stats

  • 3.6K

    Monthly active users

  • 1.5K

    Posts

  • 35K

    Comments