by Ruslan Botnar
So, who died and made JS king?
JS is widespread and in demand. You shouldn't take our word for it.
Not in a distant time and not in a faraway place, the Internet was just beginning to develop, and at this time, web browsers were needed to access it. Mosaic was the first to take the lead in this race because it was also the first browser to display images in a text line instead of displaying images in a separate window. By the way, yes, pretty cool for that time. At the time, a group of guys wanted to create an online gaming network for Nintendo, so they hired some of the Mosaic guys but ended up postponing the project. Being optimistic, they decided to use their resources in a different direction and started building a better web browser. They named their company Mosaic Communication and their first product was launched in 1994 under the name Mosaic Netscape. But they soon ran into some copyright issues and started calling it Netscape Navigator, but continued to call their internal browser "Mosaic Killer." Now for us, it is better known as Mozilla.
Netscape Navigator was a huge success and already occupied almost 75% of the entire browser market within the first 4 months of its release. It became the default browser in a short time. These guys ruled for a while, but soon they started competing with Microsoft. Microsoft was also rapidly developing and was a kind of threat to its project. And so they decided to collaborate with other guys who also had a big project. After meeting Brendan Eich, hired by Netscape, he was tasked with implementing the Scheme programming language, or something similar, into the Netscape browser.
But things didn't turn out as planned, and they ended up creating a scripting language that acts as a helper language for HTML. It was easy to use by web designers and programmers. It was developed under the name Mocha. Then it was renamed and officially called LiveScript ("Live" in translation "live"), but soon they decided to rename it again. The syntax was influenced by the C and Java languages, and since Java was a buzzword at the time and sounded good, they decided to use it.
But why is it still on the top of the list?
Both languages allow you to create a beautiful site or a separate page, the appearance of which is limited only by your imagination. However, they do not provide the interactivity of the web page. Each time the button is clicked, the page must refresh for the changes to occur.
- Prototypical programming style (instead of classes and inheritance - prototypes and cloning);
- Weak dynamic typing;
- Functions as first-class objects (that is, they can be created right at runtime).
Will JS be in demand in the future?