Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
How does JavaScript work?
Search
Ulugbek Miniyarov
May 25, 2017
Programming
0
63
How does JavaScript work?
What is Javascript: a single-threaded non-blocking asynchronous concurrent language?
Ulugbek Miniyarov
May 25, 2017
Tweet
Share
More Decks by Ulugbek Miniyarov
See All by Ulugbek Miniyarov
DDD and CQRS Quick Overview
miniyarov
0
59
Software Architecture Patterns
miniyarov
1
28
Secure Software Development
miniyarov
0
39
Introduction to Docker
miniyarov
0
27
Advanced Blockchain Topics
miniyarov
0
40
Blockchain: from 0 to 1
miniyarov
0
84
Continuous Code Quality Inspection
miniyarov
0
37
Bitcoin Scripting, Smart Contracts (Ethereum), Tokens & ICO
miniyarov
0
31
PHP7 New Features
miniyarov
1
40
Other Decks in Programming
See All in Programming
なぜ「共通化」を考え、失敗を繰り返すのか
rinchoku
1
510
deno-redisの紹介とJSRパッケージの運用について (toranoana.deno #21)
uki00a
0
150
イベントストーミング図からコードへの変換手順 / Procedure for Converting Event Storming Diagrams to Code
nrslib
1
400
AIエージェントはこう育てる - GitHub Copilot Agentとチームの共進化サイクル
koboriakira
0
380
KotlinConf 2025 現地で感じたServer-Side Kotlin
n_takehata
1
230
関数型まつりレポート for JuliaTokai #22
antimon2
0
150
明示と暗黙 ー PHPとGoの インターフェイスの違いを知る
shimabox
2
320
Go1.25からのGOMAXPROCS
kuro_kurorrr
1
800
「Cursor/Devin全社導入の理想と現実」のその後
saitoryc
0
160
AIプログラマーDevinは PHPerの夢を見るか?
shinyasaita
1
120
GitHub Copilot and GitHub Codespaces Hands-on
ymd65536
1
120
Bytecode Manipulation 으로 생산성 높이기
bigstark
2
380
Featured
See All Featured
How to Ace a Technical Interview
jacobian
277
23k
Optimizing for Happiness
mojombo
379
70k
Writing Fast Ruby
sferik
628
61k
4 Signs Your Business is Dying
shpigford
184
22k
Fantastic passwords and where to find them - at NoRuKo
philnash
51
3.3k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
8
670
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
32
2.3k
Unsuck your backbone
ammeep
671
58k
Navigating Team Friction
lara
187
15k
Code Review Best Practice
trishagee
68
18k
Build The Right Thing And Hit Your Dates
maggiecrowley
36
2.8k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
233
17k
Transcript
How does JavaScript work? Ulugbek Miniyarov Software Architect @ENUYGUN Heavily
inspired by Philip Roberts’ JSConf EU 2014 Talk
V8 Engine (Chrome’s JS Runtime) ChakraCore (Egde’s JS Runtime) Nitro
(Safari’s JS Runtime) SpiderMonkey (Firefox’s JS Runtime) JavaScript Engines:
JavaScript? A single-threaded non-blocking asynchronous concurrent language
JavaScript has a Call Stack, an Event Loop, a Callback
Queue, and some other apis (Ajax, Timing ...) Are they inside JavaScript Engines? - Only Call Stack with Heap
None
Asynchronous feature is not included in JavaScript Engine. Browsers /
NodeJS handles asynchronous part: - XHR Request - Timing (setTimeout, setInterval) - Events (onClick, onFocus i.e.)
None
The Call Stack one thread == one call stack ==
one thing at a time
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
None
Blocking And how non-blocking i/o gives asynchronicity
None
None
None
None
None
None
None
None
Demo: Blocking Script in Browser at: https://jsfiddle.net/9c9ztkvz/
Solution? Asynchronous Callback
None
None
None
None
None
None
None
Concurrency & Event Loop One thing at a time, except
not really.
None
None
None
None
None
None
None
None
None
None
None
None
None
Ready for a Quiz?
None
None
Demo Time!
Thanks