I am having a little bit of trouble of trying to filter out data that does not contain zero.
for example:
const height = {
cm: 0,
feet: 10,
inches: 5,
}
and the desired result is to remove elements that dont have zero.
so desired result is:
const height = {
feet: 10,
inches: 5,
}
i have tried
const boo = Object.keys(height).filter((e) => height[e] > 0);
but no luck.
ANy ideas