Feedback is welcomed on the efficiency of the following JavaScript/TypeScript solutions:
function whatever(param) {
if (param === x) {
doStuff();
}
}
or
function whatever(param) {
if (param !== x) { return false; }
doStuff();
}
The second option reduces blocks and enhances readability, but does it provide any advantages or disadvantages compared to the first one?