Hosted by Dailymotion. For legal issues report at the Copyright Center, report us on DMC, or use the Instant Removal tool.
5. How JavaScript Is Executed | Complete JavaScript Tutorials
4 Views • Jun 15, 2020
Description
How is the javascript code in our browser.
Execute it and not just in our browser but typically in any environment where you run javascript let's
say you write your javascript code and you wanted to have some effect on the web page.
If we talk about the browser as the environment where we run our script then you have one important
thing built into any environment where you want to run javascript code.
And that's a JavaScript engine.
It's built into the browser as I said there and chrome for example in the Chrome browser.
It's the 8.
That's the name of the engine in Firefox.
The name would be spider monkey.
And of course our browsers also even reuse these engines or have their own engines.
Now the job of the engine is to pass code so pass read and understand your javascript code.
Then on the fly compile it to machine code because machine code executes faster.
So it reads your code but it does not necessarily executed like that but instead it now takes that code
and compiles it to code which is faster to execute by the machine and then it executes that machine
code.
This all happens in the browser with the help of the JavaScript engine.
And then when that code is executed we have that in fact on our Web page.
Now important modern engines have a lot of optimization stare.
They might start executing your uncle piled code and then compile the code whilst they're also already
executing it to get started executing faster and then switch to the compiled code dynamically ends on.
So we have a lot of optimizations going on here and we will dig a bit deeper into what the JavaScript
engine is.
Exactly.
In a separate module in the course for now it is is all we need to know the browser has a built in tool
that takes our code compiles it optimize it and executes it.
And also a little bit more technical side note all of that happens on a single threat.
Now this is very technical but you might know that in a computer you have certain tasks
More from User
2. Setting Up the Project (Variables, Functions, Data Types) | Complete JavaScript Tutorials
Mega Videos
1. Module Introduction (Variables, Functions, Data Types) | Complete JavaScript Tutorials
Mega Videos
After COVID - 19 when schools will open
Mega Videos
13. Setting Up a Development Environment For JavaScript | JavaScript Complete Tutorials
Mega Videos
12. A Brief History Of JavaScript | JavaScript Complete Tutorials
Mega Videos
11. JavaScript vs Java | Complete JavaScript Tutorials
Mega Videos
Related Videos
Core JAVAScript Tutorial for Beginners | Advanced JAVA Training and Placement
mikky james
ThreeJS Hindi Tutorials for Beginners - 07 - Advanced Project Setup
CodingBaaz
JAVA Tutorials for Beginners | JAVA Scripting Tutorials for Beginners in USA,UK,Australia,Canada
mikky james
PHP tutorials, jQuert tutorials, jquery tutorials for beginners
Aimaq9a
PHP tutorials , php tutorials for beginners , tutorials for php
Aimaq9a
Beginner Friendly Full Python Tutorials(Teaser) _ Python Tutorials For Absolute Beginners In Hindi- 0
iraj-programming