Chapter 1 - Introduction to Javascript on which ReactJS library is built

If you want to learn ReactJS from scratch, you need to go one level beyond to have full knowledge of Javascript, on which the libraries like ReactJS, VueJS, Full framework AngularJS are built on. So lets deep dive, what is Javascript and how it was built and what was its usage and how it has changed the web pages that we are viewing in our browsers.

History of Javascript
Javascript logo

You all know, to access a webpage (www.google.com), you need a browser. In 1993, a browser was released named "Mosaic" which was used to show the static pages without any dynamic behavior. Then in 1994, came a updated version "Netscape Navigator" which was developed by lead developers of Mosaic under the Netscape Corporation. At time, this browser Netscape Navigator had become quite popular. Still this time also, Javascript was still not born.

Then in 1995, Netscape decided to add scripting, so that web pages can become dynamic. For this, they collaborated with Sun Microsystem, which brings the Father of Javascript "Brendan Eich" in picture. We should thankful to him and Netscape team. First language built was name as Mocha, then renamed to LiveScript which was renamed to Javascript as it released officially. 

Then, in the same timespan, Microsoft built JScript for it browser Internet Explorer. Now you might heard a term 'ECMAScript' which is frequently heard with Javacript. To solve difference between languages like Javascript & JScript and browsers to have a standard, Netscape and Microsoft agreed on ECMAScript. Full form of ECMAScript is European Computer Manufacturer's Association. So from that year to till now, ECMAScript releases its version. You might heard names like ES6 or ES2015. So you know ECMAScript is a standard that what is supported and how it should work in Javascript.

Then in 1998, some members of Netscape created Mozilla, which helped in contributing to open source community. Mozilla resulting into Firefox which you might be using to browse web pages. These browser have engines which should be ECMA compliant to run, compile javascript. 

Browser Engines

SpiderMonkey is the engine of Mozilla firefox. Likewise 'Chakra' is the engine of Internet Explorer. Then in 2008, comes the main engine named as V8. And the browser in which it comes, is none other than Google chrome, which is the most widely used browser at the moment. 

Use of Javascript in backend and birth of NodeJS

nodejs logo
Before the birth of NodeJS in 2009, it was not that Netscape didn't tried to use Javascript as Backend language. About 10 years ago, Netscape built Netscape LiveWire for the same. But didn't quite run well. So in 2009, Ryan Dahl took the open source V8 engine of chromium used in Google Chrome browser and the took the capabilities of Javacript to run in backend as Server. 

Package manager of Javascript (NPM)

Like other programming languages have their package manager, which is use to download packages built by community which helps for the development. Node package manager (NPM) is built in javascript and was developed by Isaac Z. Schlueter. Npm is not only the one. There are many others Yarn, pnpm, ied and npmd etc. So any project based on React, React Native, NodeJS backend, Firebase Cloud functions would have a similar structure, having a main file package.json. This file contains all packages which is need by project. By the command like 'npm install'. Don't worry, if it is going over your head. Will cover in details in later chapter.

Entry of Javascript in Mobile App Development
react native logo

Now as Javascript developer. May be he/she can be frontend, backend or a fullstack developer. But why to limit to only web development. Typically two popular app channels are Android and IOS as of now. So if someone builds a app, it has to be build separately for Android and IOS. But here comes React Native by Facebook in 2015, which helps you write code in Javascript and your code are build in Android and IOS automatically. Which means if you know javascript, you can know build apps for your website.

Typescript
typescript logo

TypeScript is a programming language developed and maintained by Microsoft. It is designed to support large application which are having many files and lines of code. TypeScript is JavaScript with syntax for types. TypeScript adds additional syntax to JavaScript to support a tighter integration with your editor. Catch errors early in your editor. Example, you create a function that takes one params and it must be string. So whenever you are writing that function anywhere, it already shows error if param is missing or its type is not string. So basically it provides proper structure for larger projects.

Hope, this is enough for having an basic overview of what is Javascript, how it has changed over years. Leave your comments and useful knowledge, so it helps to build a very informative community.


Comments