Skip to Content
  • Website
Codsen
  • Home
  • Open Source
  • Articles
  • About

backOpen Source→util-nonempty→Examples

Table of Contents

  • Quick Take
  • Check whether an array contains a value
  • Treat a deeply nested array as non-empty
  • Treat every number, including zero and NaN, as non-empty
  • Check whether an object contains a property
  • Treat nullish and Boolean values as empty
↑ back to top

Quick Take

↑ back to top

Check whether an array contains a value

↑ back to top

Treat a deeply nested array as non-empty

↑ back to top

Treat every number, including zero and NaN, as non-empty

↑ back to top

Check whether an object contains a property

↑ back to top

Treat nullish and Boolean values as empty

↑ back to top
back 

Copyright

All rights reserved © Roy Revelt 2026
All our open source packages are under MIT licenceopens in a new tab

Activities

🐛 See a bug? Raise an issueopens in a new tab
💘 Check out the Indiewebopens in a new tab and Libera manifestoopens in a new tab