Understanding weirdness of the β€œ!” bang operator in JavaScript

There are some things we don’t know about how theΒ ! operator works in Javascript. Basics TheΒ ! is a logical operator that will convert a value to its opposite boolean. Since JavaScript will coerce values, it will β€œconvert” a value to its truthy/falsey form and return the opposite boolean value. When we perform theΒ ! operation on …

Design a site like this with WordPress.com
Get started