What is script type=module ?
A script tag having type=module attribute specifies that it to be considered as a Javascript module. It may be importing other Javascript module(s) inside it and becomes a top-level module for the imported modules.
How to Prevent Disqus Comments System from Slowing Page Speed & Performance
Loading Disqus' script files and comments on page load can lower down speed and performance of the page, specially in mobiles. A solution would be to use an Intersection Observer to lazily load Disqus.
How to Detect Number of Processor Cores with Javascript
The number of available logical processor cores in the device can be found with the navigator.hardwareConcurrency Javascript property. This number can be useful in knowing how many Web Workers can be executed in parallel.
Javascript KV Storage Introduction Tutorial
KV Storage API is an asynchronous way to save data in the browser using Javascript Promises. Its asynchronous nature guarantees that the performance of the application is not impacted.
How to write Immediately-invoked / Anonymous Async Functions (IIFE)
An anonymous async function can be defined using the Immediately-invoked Function Expression pattern for asynchronous functions.
How to Convert Array to a String in Javascript
A Javascript array can be converted to a string by using the join() method to join elements of the array separated by a given character or string.
How to Implement Click to Call Feature in Web Pages
Click to Call functionality in web pages can be implemented using the tel: schema inside a hyperlink. Clicking on such a link would open the Dialer App on the device.
How to Create QR Codes in JavaScript
QR codes have become really popular these days. In web pages QR Codes can be generated using the QRCode.js Javascript library.
How to Prevent Form Validation on Page Load & While Typing on Input Field (HTML Constraint Validation API)
The Constraint Validation API validates HTML forms on page load, and while typing on an input field. This seemingly confusing behavoiur to the user can be modified using a bit of CSS and Javascript.
How to Change the Theme Color of the Address Bar in Mobile Browsers
The theme color of the address bar in mobile browsers can be changed using the theme-color meta tag. Any CSS color value can be set as its content.
How to Remove Duplicates from an Array using the Set Datatype
Duplicate elements can be removed from a Javascript array using the Set data type. A Set object can be created from the array, and then the Set can be converted back to an array.
How to Assign Default Values to Function Parameters in JavaScript
Function parameters can be initialized with a default value in the parameter list itself using ES6 default parameters.
How to Convert String to Number in Javascript
The Number() method can be used to convert a string containing numeric characters to a number upon which mathematical operations can be done.
How to Check Number is Positive or Negative in Javascript (ES6 Way)
The Math.sign() is a new method introduced in ES6 that can be used to find whether a number is positive or negative or a zero.
How to Get the Integer Value from a Decimal Number in Javascript
The Math.trunc() method can be used to truncate the fractional portion of a number. The number can also be rounded to the next integer using Math.round(), Math.ceil() and Math.floor() methods.
HTML〈address〉Tag - Setting Address Information for a Webpage
The HTML〈address〉 element represents address information for the webpage. It can be read by machines and scripts for understanding that the included content is an address of some sort.
How to Create a Checkmark / Tick with CSS
A checkmark or a tick icon can be created with pure CSS by drawing two straight lines and rotating them.
HTML〈mark〉Tag - Marking Text of Special Importance
The HTML〈mark〉element can be used to highlight text of special relevance in a webpage. This tag can be read by machines, bots, screen readers etc to use the highlighted for their learning purposes.
Handling HTML Checkboxes with Javascript
This tutorial explains how to manipulate HTML checkboxes with Javascript. Most of the operations can be performed through the checked property of the checkbox DOM element.
How to Access "this" in Event Handlers and Callbacks with globalThis Property
The globalThis is a global property referring to the global object. This makes it very easy to access this inside callbacks, event handlers, inner functions etc.