loading...

re: There's no "else if" in JS VIEW POST

TOP OF THREAD FULL DISCUSSION
re: I'm intrigued by what you said about if-statements. I'm curious to know how you would write the following callback function. someRequest(URL, (...

You could use something like promises.

someRequest(URL)
.then(result => console.log(result))
.catch(err => console.log(err));

Ooh. That's right. Forgot promises could do thatπŸ˜…. Thanks 😊

code of conduct - report abuse