DEV Community


Discussion on: How do you deal with null vs undefined?

functional_js profile image
Functional Javascript • Edited

In JS I don't think in terms of null or undefined, but think in terms of "nil".
I use a utility func similar to Ramda's R.isNil.

And I have a complement func called, isNotNil

Alt Text

Source Code:

Forem Open with the Forem app