Is this serious? I started programming around 9 or 10 on a Commodore 64. I would go to the local library to get programming books for it. Now you can hit F12 in your browser and get a powerful console into JS. JS is fine, encourage the thirst for knowledge.
JS is an objectively bad programming language. It is not fine, it is just annoyingly common and convenient. The main advances in its ecosystem are related to transpiling it from other, saner, languages. If he has fun writing JS, then great for him. He's 12, he'll do it if he wants. But it'd be doing him a disservice not to open his eyes to much wider, greener pastures of the programming world.
JS was my second language (around the same age as he is, which is more than 15 years ago) and it is still my favourite one. You give zero arguments but I won't make the same mistake:
- devtools are unmatched for browser development (and getting better for node)
- absolutely best language for prototyping (dyn. typing, monkey-patching, eval, and a lot of other "evil" things you usually don't need in further phases but it's really great to have them for this exploratory phase)
- I respect that some people prefer static typing and code-completion but I prefer writing tests and having few well-known libraries for which I don't need completion at all
- no threads, no mutexes, no locks
- object literal, rest-spread, destructuring, classes are just ordinary (and mutable) objects, etc...
If you think people are doing JS just because it's the only language in the browser (not true anymore) you should seriously reconsider. There were to-js compilers before and it was always awful (remember gwt? dart?)
Of course, it depends on use-case, JS is not the best language for everything.
JS is a bad language but it's the easiest environment to set up.
Back in the day we started with Qbasic not because it is a good language but because that was easy to set up, we all had it and our friends had it and our school computers had it.
That's debatable.
It's not as if downloading Python and making your first app will take you more than a few seconds, minus download time.
Set up is rarely an issue, once you set up a language even as complex as C++ its completely automated. You press a button and magic happens.
If the biggest selling point of a programming language is that it comes preinstalled with the OS of your choice, its not much of a selling point when the average user downloads and installs GBs of data just to play the latest game hype like Fortnite.
The only people who mind installing stuff are predominately web devs. 99.9% of users out there are fine with it for more than 6 decades now and that wont be changing any time soon.
It does make a difference especially to a beginner or a child. You might not have admin privileges at your school or your friends may not be able to install those tools so you can't show your work.
But you can hack away on any computer with a browser.
there are tons of services only that will allow you to code online using any language eve C , C++ and Assembly. From inside the browser of course. Of course I am not recommending a beginner to start from any of those languages but it shows that JS does not have the monopoly of in browser coding. If you have to stick with browser no matter what.
Transpilation certainly has been important, but in no way is that the only or even the most important advance. The most significant advances are the massive changes in architecture that have turned it into a modern, fully-featured language. You can use most of those in all modern browsers right now. It might not be the best language, and isn't a great choice for a first language to learn, but it is a good one to learn next.
see how that sounds? that's how you js haters sounds each time I see this bs here on this and many other platforms that wouldn't be possible without js.
I used to be a frontend dev. I have written hundreds of thousands of lines of production JS code for apps that many Hacker News users use on a regular basis. I well understand how much JS has made possible. The web would not be the same without it. But that doesn't mean it's a good programming language.