Clone and edit this document
Runkit
Runkit
home page
user forum
new notebook
clone notebook
download notebook
support & documentation
log in
sign up
new notebook
help & feedback
clone this notebook
download this notebook
Sign In
Sign Up
undefined and null check
node v18.11.0
version:
1.0.0
endpoint
share
tweet
var _ = require("lodash@4.17.15") _.assign(global, require("lodash-doc-globals")) Object.observe = _.noop
const coords = { lat: 0, lng: 0 }; console.log(_.isEmpty(coords)); // false console.log(typeof coords.lat !== 'undefined'); // true console.log(coords.lat !== null); // true
Created from: https://lodash.com/docs/4.17.15#isEmpty
Loading…
no comments
sign in
to comment