When dinosaurs lived:
- JavaScript's design was influenced by several programming languages: namely Scheme, Self, Java, C, Perl.
The core language does "NOT" includes:
- Read keyboard input
- Display output on a screen
- Access the file system
- Make HTTP requests
- Manipulate web pages
- Create windows or dialogs These capabilities are provided by the host environment.
Host Environment means the web browser, Or Node.js (a run time "environment").
Host environments provide I/O
- Web Browser
- console.log()
- document
- window
- fetch()
- alert()
- Node.js
- console.log()
- fs
- http
- process
- readline
Although console.log() is commonly used, it is not part of the ECMAScript specification. It is provided by browsers, Node.js, and other JavaScript environments.
The core language includes:
- Numbers (Number, BigInt)
- Text (String)
- Booleans (Boolean)
- Arrays (Array)
- Objects (Object)
- Sets (Set)
- Maps (Map)
- Dates (Date)
- Regular expressions (RegExp)
- Promises (Promise)
- JSON
- Math utilities (Math)
Most Common Uses
- One of Node.js's most common uses is building web servers and APIs.
- Node.js is also convenient for writing command-line utilities that automate tasks such as:
- Reading and writing files
- Renaming or organizing files
- Processing CSV or JSON data
- Running build scripts similar to python
- Automating deployments
- Call REST APIs (fetch, http, https)
To be continued...
Top comments (0)