Warning
|
Github does not support asciidoc pretty well so if the source code not shown then blame github 🙃 |
What I learn in this section is well explained material to NodeJS and Learn how to build simple API using it, such as:
-
What is Node JS and Why Use It?
-
Running JavaScript Outside the Browser
-
Using Modules
-
Basic Reading and Writing File
-
Blocking and Non-Blocking: Asynchronous Nature of Node JS
-
Basic Reading and Writing File Asynchronous way
-
Creating a Simple Web Server
-
Routing
-
Build a Very Simple API
-
HTML Templating: Build the Templates ad Filling the Templates
-
Parsing Variables from URLs
-
Introduction to NPM and the package.json
-
Type of Packages and Installs
-
Package Versioning and Updating
Note
|
I will explain every single point later, maybe :D, it’s my own notes anyway :b |
In this section I learn about basic knowledge how Web works, HTTP and others, such as:
-
An Overview of How the Web is Works
-
HTTP in Action
-
Front-End vs. Back-End Web Development
-
Static vs Dynamic vs API
Note
|
same as above (: |
This Section is actually more deep explained about how Node JS work behind the scenes, such as:
-
Node, V8, Libuv and C + Node JS is actually built with V8 engine (not a car engine) from Google using Libuv Library and Using C Programming Language
-
Processes, Threads and Thread Pool
From what i get from this Section, Node JS is Single threated application, meaning that Node JS is just using 1 (one) thread to handle request. And using Thread Pool (Thread that Node JS use to actually process the request(process it in background (honestly I don’t really know about this, maybe I will repeat this section again later))) -
The Node JS Event Loop
-
Events and Event-Driven Architecture
-
Introduction to Streams
Streams is used to read a large amount of data, such as large file, video, etc. -
How Requiring Modules Really Works
From this section, I learn about how callback can ruin our code.
-
The Problem with Callbacks: Callbacks Hell
Here is the Example:link:./async-promise/callback-hell.js[role=include]
See how the code making the triangle shape? Well, that’s the point of this section, to get rid of that triangle by using bellow method.
-
From Callback Hell to Promises
Promise is basically the future value that we expect to get from a function. Here is the recreate of above code using promises:link:./async-promise/promise.js[role=include]
Promises make the code easier to understand and maintain.
-
Consuming Promises with Async/Await
Async is basically mean Asynchronous, that means a function with async will performing the code that’s in the function, while the rest of the code keeps running in the Event Loop (Without blocking the Event Loop). Await is used in inside of the async function, await will sotop the code and wait for promises function until it’s get the value. Here is the example of Async/Await :link:./async-promise/async-promise.js[role=include]
-
Returning Values from Async Functions
-
Waiting for Multiple Promises Simultaneously
-
What is Express?
Express is framework for Node JS to build a web application. The short is this module can make our application build process a little bit easier then without using it. -
Postman Intro
Postman is an application to access and test our API. -
Setting up Express and Basic Routing.
In this section the lecturer explain about how to actually using Express and setup a basic routing using it. -
API and RESTful API design
API is stands for Application Programming Interface : a piece of software that can be used by another software, in order to allow application to talk to each other.