Wednesday, July 31, 2024

JavaScript

 What is JavaScript?

What Can you do with it?

Where does JavaScript code run?

Difference between JavaScript and ECMA Script ?


 What is JavaScript?

One of the most popular scripting languages used by most popular companies

What Can you do with it?

In past JavaScript used in browsers to build interactive web pages as toy language .

Today we have huge community support and Industry contributions (FB,Google..)

Used to create full blown Webs, Mobile apps, real time networking apps, command line tools , games.

Where does JavaScript code run?

Originally designed to run in Browsers. So all browsers has JavaScript Engine - execute JavaScript code.

JavaScript engines in FireFox -> SpiderMonkey , Chrome -> V8

 In 2009 --> Brian Doll

Took the open source JavaScript engine from Chrome and embedded inside C++ program. --> Node

With this we can run JavaScript outside Browser

Summary 

JavaScript can be run inside Browser or Node.

Difference between JavaScript and ECMA Script ?

ECMA - Specification - define standard ( European Computer Manufacturers Association )

JavaScript is the language - which confirms this ECMA specification.

First Spec released on 1997 then after 2015,2016.... 

1997 - v1

2015 - ES2015/ES6


Let's try JavaScript in Browser 

Open browser , click anywhere and go to Inspect --> dev tools

write

> console.log('Hello World');

Press Enter

Hello World

> 2+2

< 4



No comments:

Post a Comment