-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathJavascriptInternalWorking.txt
62 lines (49 loc) · 4.34 KB
/
JavascriptInternalWorking.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
Hello coders,
I have written this blog which is gonna be exploring Javascript technology and its features
What is javascript and its feature
In the beginning of the internet, websites were primarily with basic HTML and limited interaction.But everything changed when JavaScript was introduced, enabling the creation of lively, interactive, and captivating web applications.
JavaScript was developed by Brendan Eich for Netscape 2, and by 1997,
Created to improve the customer side of websites, JavaScript added movement to static HTML pages with lively and engaging parts.
Javascript in its early days was called Livescript and was inspired by Java language syntax therfore these two languages share some similarites of syntax.
Brendan submitted his work thrugh netscape to Ecma International,
an organization that develops and publishes technical standards, to formalize and detail how this scripting language should be understood by other browsers
(In 1997, Ecma International published ECMA-262, making the initial version of a scripting language known as ECMAScript a standard.)
JavaScript is based on a set of rules called ECMAScript (or ES for short). Over time, these rules have been updated to add new features to the language.
ES5 (launched in 2009) was one of the initial significant updates to these regulations. Prior to ES5, modifications to JavaScript were minor and not well structured.
ES6, also known as ES2015, was a significant 2015 update which introduced numerous fresh elements into JavaScript, such as arrow functions, classes, and promises.
After ES6, instead of significant updates, the regulations began receiving smaller updates annually. Therefore, we currently have ES2016, ES2017, and subsequent, with each year introducing additional functions to JavaScript.
ES5 and ES6 are two different editions of JavaScript. ES6 is a newer version that came with many useful features that developers use now.
Statements in Javascript
Statements are nothng but a unit of code that can be used to perform a action in javascript like declaring and initializing a value to a variable
let variable = 6
myVariable
> 6
Note=There is a very unique feature in javascript which I have liked is that statement does'nt neccesarily required semicolon like u can see in the above code in which i have declared a variable "a"
This feature is called "automatic semicolon insertion" which automatically inserts you a semi colon for you after your statement ends becuase many times while writing code in other languages we can get error about a semicolon missing but javascript avoids that by using these feature.
Weakly typed language
javascript is a very weakly typed language or should i say a funny language when it comes down to data type checking and handling.
In JavaScript, you can mix and match different data types in ways that other programming languages wouldn’t allow. For example, you can add a string to a number, and JavaScript will try to make sense of it rather than throwing an error.
"2" + 44
>244 //output
5 + true
>6
Case sensitivity
Javascript is a fully case sensitive language means there is a difference between A variable and a variable
A=6
A
>6
a=7
a
>7
You can also try in your browser consoole
Javascript runtime
JavaScript can run in the browser console because web browsers have a built-in JavaScript engine that interprets and runs JavaScript code. When you access the console in your browser (typically by pressing F12 or Ctrl + Shift + I), you are directly engaging with this engine.
You can tyr it too in your browser
Web browsers utilize the JavaScript engine to create dynamic and interactive websites. When you enter JavaScript code into the console and hit enter, the browser right away interprets and executes that code using the engine.
By using these console
we can write some small snippet of code
Can play with the elements of a any webpage
Google Chrome utilizes the V8 engine, whereas Firefox utilizes SpiderMonkey, both of which are robust tools to interpret and execute JavaScript in the browser.
I'll surely be explaing the v8 engine which chrome uses for javascript interpretation
In summary, web browsers have built-in support for JavaScript, which means you can run JavaScript code right away in the console!
That's it for this blog Thanks for reading this and raise a issue if there is a error in this blog