JSFiddle - React, Tailwind, and code Playground
JavaScript
var foo = undefined;
// outputs undefined
console.log(foo)
// typecast to non-inverted boolean
console.log(!!foo);
if (!!foo) {
console.log("If was false before, why won't this execute?");
} else {
console.log("It didn't work");
}