You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: Learn/1. Introduction.md
+4-6Lines changed: 4 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -22,7 +22,7 @@ When someone (user) visit and interact the **Client** (browser), a **request** i
22
22
23
23
## How Is JavaScript Executed?
24
24
25
-
When you write your **JavaScript** code and you want it to have some effect on the web page, if we talk about the browser as the environment where we run our script. The you have on 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 we said. For example, in the chrome browser, it's **v8**, that's the name of the engine. In firefox the name would be **spider monkey**. Other browsers also either reuse these engines or have their own engine.
25
+
When you write your **JavaScript** code and you want it to have some effects on the web page, if we talk about the browser as the environment where we run our script. The you have on 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 we said. For example, in the Chrome browser, it's **v8**, that's the name of the engine. In Firefox the name would be **spider monkey**. Other browsers also either reuse these engines or have their own engine.
26
26
27
27
The job of **engine** is to parse your **JavaScript** code (parse, read and understand), then compile it to machine code. Because machine code executes faster, so it (machine) reads your code but it does not necessarily execute it 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. Then when that code is executed, we have that effect on our web page. **JavaScript** engine executes the code from top to buttom (waterfall).
28
28
@@ -58,17 +58,17 @@ What is it mean? It means that we can use **JavaScript** in **Browser-side** and
58
58
59
59
-**JavaScript** was invented to create more dynamic websites by executing in the browser! That's the origin of **JavaScript**.
60
60
61
-
-**JavaScript** can manipulate the HTML code, CSS, send background Http requests and allows interaction with web page and browser APIs (e.g. get user location) and much more.
61
+
-**JavaScript** can manipulate the HTML code, CSS, send background HttpRequests and allows interaction with web page and browser APIs (e.g. get user location) and much more.
62
62
63
-
-**JavaScript** can't access the local filesystem (interact with the operating system etc.).
63
+
-**JavaScript** can't access local filesystem (interact with the operating system etc.).
64
64
65
65
> in other-side (e.g. server-side like Node.js):
66
66
67
67
- Google’s **JavaScript** Engine (V8) extracted to run **JavaScript** anywhere (called **Node.js**).
68
68
69
69
-**Node.js** can be executed on any machine and is therefore often used to build web backends (server-side **JavaScript**).
70
70
71
-
-**Node.js****can** access the local filesystem, interact with the operating system etc. It **can't** manipulate HTML or CSS.
71
+
-**Node.js****can** access local filesystem, interact with the operating system etc. It **can't** manipulate HTML or CSS.
72
72
73
73
## What will you learn in this course?
74
74
@@ -102,8 +102,6 @@ There are **three** levels of learning in this course:
102
102
103
103
## Useful Resources & Links
104
104
105
-
The following resources may be helpful for starting your journey:
106
-
107
105
- VS Code Docs: <https://code.visualstudio.com/docs>
108
106
109
107
- VS Code Keybindings: <https://code.visualstudio.com/docs/getstarted/keybindings>
Copy file name to clipboardExpand all lines: Learn/18. JavaScript Modules.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -62,7 +62,7 @@ export class Component {
62
62
63
63
For use modular code, you need:
64
64
65
-
1. You need to install **NodeJS** app in your computer. Then use `npm install -g serve` command for install a custom web server. You can use it with `serve` command in **NodeJS**. Or you can use google chrome web server plugin to use it.
65
+
1. You need to install **NodeJS** app in your computer. Then use `npm install -g serve` command for install a custom web server. You can use it with `serve` command in **NodeJS**. Or you can use google Chrome web server plugin to use it.
66
66
2. For the `app.js` file, you need to set the `type` attribute and `module` for its value. For example:
You need to install **NodeJS** app in your computer. Then use `npm install -g serve` command for install a custom web server. You can use it with `serve` command in **NodeJS**. Or you can use google chrome web server plugin to use it.
130
+
You need to install **NodeJS** app in your computer. Then use `npm install -g serve` command for install a custom web server. You can use it with `serve` command in **NodeJS**. Or you can use google Chrome web server plugin to use it.
131
131
132
132
We can see or get our cookie easily with `document.cookie` code, for example:
133
133
@@ -267,7 +267,7 @@ More on Cookies: <https://developer.mozilla.org/en-US/docs/Web/API/Document/cook
267
267
268
268
## IndexedDB
269
269
270
-
IndexedDB is the most complex storage. You need to install **NodeJS** app in your computer. Then use `npm install -g serve` command for install a custom web server. You can use it with `serve` command in **NodeJS**. Or you can use google chrome web server plugin to use it.
270
+
IndexedDB is the most complex storage. You need to install **NodeJS** app in your computer. Then use `npm install -g serve` command for install a custom web server. You can use it with `serve` command in **NodeJS**. Or you can use google Chrome web server plugin to use it.
271
271
272
272
Let's start with indexedDB. For that, we must create a database request with `window.indexedDB.open("name", version)` (you can omit the `window` object):
Copy file name to clipboardExpand all lines: Learn/26. Performance Optimizations.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -61,7 +61,7 @@ There are a couple of different ways of measuring it. As we mentioned, the brows
61
61
62
62
## Woking with Chrome DevTools
63
63
64
-
- We can check the **Elements** tab in google chrome browser. We can see the highlight of elements when they were changed, added and removed. For example, if you have a list item (`ul` with some `li`s), when you delete one of that (list), all lists will be highlighted and it is related to the performance topic.
64
+
- We can check the **Elements** tab in google Chrome browser. We can see the highlight of elements when they were changed, added and removed. For example, if you have a list item (`ul` with some `li`s), when you delete one of that (list), all lists will be highlighted and it is related to the performance topic.
65
65
66
66
- We can go to the **Network** tab and at the top of the page, we select the **slow 3G** mode and enable the `Disable caches` checkbox (for disabling the cache). Now if we have a script file more than `1MB`, the buttons and other elements will not work anymore until the file is downloaded. This is now why a too large script file could be a problem.
0 commit comments