javascript - How can I tell if an object is empty? -


this question has answer here:

i hope makes sense. if have object:

 var = {"minlength":true}  var = {} 

how can tell if object empty (the second line of code)

object.keys(a).length === 0 

should trick.


Comments

Popular posts from this blog

Java 8 + Maven Javadoc plugin: Error fetching URL -

android - How to delete or change the searchview icon inside the SearchView actionBar? -

c++ - Msgpack packing bools bug -