JavaScript just isn't the "chaotic disaster" many try to paint it as anymore. Sure, you can write it in a chaotic way, but the level of understanding and education has helped make it easier for people coming into JavaScript actually do well, and avoid the major stumbles that caused issues in the early days. Add in advances to the language itself over the lat few years, and it's a very solid language.