nodejs remove all keys with empty string from object code example
Example: es6 remove empty property from object
Object.entries(obj).reduce((a,[k,v]) => (v == null ? a : (a[k]=v, a)), {})
Object.entries(obj).reduce((a,[k,v]) => (v == null ? a : (a[k]=v, a)), {})