Node.js Process Complete Reference
A process object is a global object that gives information about and controls the node.js process. As it is global, it can be used in the project without importing it from any module....
read more
Node.js response.removeHeader() Method
The response.removeHeader() (Added in v0.9.3) property is an inbuilt property of the ‘http’ module which removes a header identified by a name that’s queued for implicit sending. The header name matching is case-insensitive. The object returned by the response.getHeaders() method does not prototypically inherit from the JavaScript Object....
read more
Why we use setTimeout() function in Node.js ?
The purpose of setTimeout function is to execute a piece of code after a certain interval of time. The setTimeout() function accepts two arguments. The first argument is a function and the second argument is time in milliseconds. The setTimeout() executes the function passed in the first argument after the time specified in the second argument. The setTimeout function doesn’t block other code and the rest of the code is executed and after a specified time the code inside setTimeout function is executed....
read more
Send Message to WhatsApp using Twilio in Node.js
We all use WhatsApp in our daily life to send text messages to one another. We can send WhatsApp messages using the Twilio API in NodeJS using the following approach....
read more
Node.js OS Complete Reference
Node.js OS module provides information about the computer operating system....
read more
Node.js http.server.keepAliveTimeout Property
The http.server.keepAliveTimeout is an inbuilt application programming interface of class Server within http module which is used to get the number of milliseconds of inactivity a server needs to wait for additional incoming data....
read more
Node.js response.getHeaders() Method
The response.getHeaders() (Added in v7.7.0) method is an inbuilt method of the ‘http’ module which returns a shallow copy of the current outgoing headers. Since a shallow copy is used, array values may be mutated without additional calls to various header-related http module methods. The keys of the returned object are the header names and the values are the respective header values. All header names are lowercase....
read more
Node.js console.assert() Method
The console.assert() method is an inbuilt application programming interface of the console module which is used to assert value passed to it as a parameter, i.e. it checks whether the value is true or not, and prints an error message, if provided and failed to assert the value....
read more
Node.js crypto.timingSafeEqual() Function
Node.js is a cross-platform, open-source back-end JavaScript runtime environment that uses the V8 engine to execute JavaScript code outside of a web browser. Node.js allows developers to utilize JavaScript to create command-line tools and server-side scripting, which involves running scripts on the server before sending the page to the user’s browser. Cryptographic functionality is provided via the crypto module, which includes wrappers for OpenSSL’s hash, HMAC, cypher, decode, sign, and verify methods....
read more
Node.js prompt.get() Method
The prompt.get() method is an asynchronous function. This method takes strings representing property names in addition to objects for complex property validation (and more). This function is used for I/O operations....
read more
How to test internet speed using Node.js ?
The following approach covers how to do an internet speed test in NodeJs. We will use the speed-test node-package to achieve so. This package will help us for getting the current download and upload speed....
read more
Node.js assert.doesNotThrow() Function
The assert module provides a set of assertion functions for verifying invariants. The assert.doesNotThrow() function asserts that the function fn does not throw an error....
read more