馃殌 CYBER WEEK SALE: 50% OFF on JavaScript Fundamentals 馃挭

How to get current URL in JavaScript

When it comes to working with URLs in JavaScript, there are a few different ways to get the current URL that you are on. In this article, we will go over some of the different methods that you can use to get the current URL in JavaScript....

January 12, 2022 路 2 min 路 Coderslang Master

What is a double negation !! in JavaScript and how it works

Double negation is a common JavaScript trick that allow you to convert different types to boolean. Here鈥檚 how double negation works in JS. ...

January 11, 2022 路 1 min 路 Coderslang Master

How to copy to clipboard in JavaScript

There are 3 main ways you can copy something to clipboard with JavaScript. The main one is the Async Clipboard API. It reads the text from DOM and places it on the clipboard. ...

January 10, 2022 路 1 min 路 Coderslang Master

How to get a timestamp in JavaScript

Every date in JS can be represented as a number of milliseconds since Jan 1, 1970. Here鈥檚 how you can get the timestamp value from any JavaScript date. ...

January 9, 2022 路 1 min 路 Coderslang Master

Validate an email address with a JavaScript regular expression

In JavaScript, the best way to reliably verify that a string is a valid email is by using a regular expression. Here鈥檚 how it鈥檚 done. ...

January 8, 2022 路 2 min 路 Coderslang Master

How to deep clone JavaScript objects efficiently

Learn how you can implement fast deep cloning of objects in JavaScript. ...

January 7, 2022 路 1 min 路 Coderslang Master

The difference between "let" and "var" in JavaScript

Both let and var allow you to create variables in JavaScript. The main differences between them are scope, hoisting and closures. ...

January 6, 2022 路 3 min 路 Coderslang Master

The Difference Between JavaScript Equality Operators == and ===

The difference between double and triple equals equality operators in JS is the typecast. While strict equality immediately returns false if the operand types are different, loose equality operator first tries to convert both values to a common type....

January 5, 2022 路 1 min 路 Coderslang Master

How to check if an HTML element is visible or hidden with jQuery

There are 2 jQuery selectors that can help you determine whether an HTML element is visible or not. First, you can use the selector :visible to check if an element is visible on the web page....

January 4, 2022 路 1 min 路 Coderslang Master

How to clear NPM cache and save space

Node Package Manager, or npm is an integral part of the modern JavaScript apps. Anytime you install an npm package, the package manager will cache the files for faster access in the future. Let鈥檚 see how you can save disk space by clearing the NPM cache. ...

January 1, 2022 路 1 min 路 Coderslang Master