From Dev.to
Why Your `if / else` Took the Wrong Branch: 4 JavaScript Condition Traps
"My if is wrong" is almost never true. The if did exactly what you wrote. It just took a different branch from the one you had in your head. That gap between the branch you expected and the branch tha...
