if statements. These statements often look like,
typeof val === 'function' or
val > other. Many times this type of code is verbose or error prone (plus you have to leave the main area of the keyboard). Some errors can be avoided by using a tool like JSHint, but some projects (legacy or otherwise) can't make room for that. While I definitely encourage the use of JSHint, we can remove some of that linting burden off JSHint's shoulders by using functions to test the truthyness of values.
I've finally decided to take writing a coding blog seriously. There are a couple of reasons in which why:
- The programming community gains another resource.
- Teaching is one of the best ways to learn.