how to delete property from object + ES6 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)), {})