Skip to content

Commit 01f3e5d

Browse files
10-Asynchronous JavaScript code added
1 parent 3d1c5db commit 01f3e5d

File tree

2 files changed

+30
-0
lines changed

2 files changed

+30
-0
lines changed
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Asynchronous JavaScript Fundamentals 🚀🔥
2+
3+
- JavaScript is a Synchronous Language by default but we can modify it to Async. Line by Line Code is Executed.
4+
- JavaScript is a Single threaded Language.
5+
6+
### Execution Context
7+
8+
- Execute one line of code at a time.
9+
- Each operation waits for the last one to complete before executing.
10+
11+
Watch Video - **_Execution Context_**
12+
1.Global Execution Context (GEC)
13+
2.Function Execution Context (FEC)
14+
3.Memory Heap --> // - Memory Creation Phase (Creation Phase) --> Space is allocated to declared variables and can't execute here.
15+
4.Call Stack
16+
17+
## Blocking Code Vs Non-Blocking Code ✅
18+
19+
Blocking Code ✔️
20+
21+
- Block the flow of program
22+
- Read File Synchronously
23+
24+
Non-Blocking Code ✔️
25+
26+
- Doesn't block execution
27+
- Read File Asynchronously
28+
29+
30+
![Image](Async%20Await.jpg)
46.8 KB
Loading

0 commit comments

Comments
 (0)