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
61
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
52
Software Architecture Patterns
miniyarov
1
23
Secure Software Development
miniyarov
0
34
Introduction to Docker
miniyarov
0
20
Advanced Blockchain Topics
miniyarov
0
38
Blockchain: from 0 to 1
miniyarov
0
78
Continuous Code Quality Inspection
miniyarov
0
31
Bitcoin Scripting, Smart Contracts (Ethereum), Tokens & ICO
miniyarov
0
29
PHP7 New Features
miniyarov
1
36
Other Decks in Programming
See All in Programming
2024年のWebフロントエンドのふりかえりと2025年
sakito
1
240
Immutable ActiveRecord
megane42
0
140
『品質』という言葉が嫌いな理由
korimu
0
160
Introduction to kotlinx.rpc
arawn
0
670
Amazon ECS とマイクロサービスから考えるシステム構成
hiyanger
2
520
ファインディLT_ポケモン対戦の定量的分析
fufufukakaka
0
490
ペアーズでの、Langfuseを中心とした評価ドリブンなリリースサイクルのご紹介
fukubaka0825
2
310
社内フレームワークとその依存性解決 / in-house framework and its dependency management
vvakame
1
550
知られざるDMMデータエンジニアの生態 〜かつてツチノコと呼ばれし者〜
takaha4k
4
1.3k
SpringBoot3.4の構造化ログ #kanjava
irof
2
980
第3回 Snowflake 中部ユーザ会- dbt × Snowflake ハンズオン
hoto17296
4
370
Ruby on cygwin 2025-02
fd0
0
140
Featured
See All Featured
Gamification - CAS2011
davidbonilla
80
5.1k
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
47
5.2k
Code Reviewing Like a Champion
maltzj
521
39k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
28
9.3k
Stop Working from a Prison Cell
hatefulcrawdad
267
20k
Designing Experiences People Love
moore
139
23k
Imperfection Machines: The Place of Print at Facebook
scottboms
267
13k
Become a Pro
speakerdeck
PRO
26
5.1k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
251
21k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
49
2.3k
Being A Developer After 40
akosma
89
590k
Six Lessons from altMBA
skipperchong
27
3.6k
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