JSFiddle - React, Tailwind, and code Playground

by mischa

JavaScript

//var test = null;

//if (!test) {
//    document.write("I thought I was falsy");
//} else {
//    document.write("WTF!");
//}


function testF() {
    var blah = "a";
    testCB(function(blah) {
        blah = blah;
        document.write("Cb: " + blah);
    });
    document.write(" and: " + blah);
}

function testCB(cb) {
    cb("b");
}

testF();