vendredi 13 février 2015

How to return an array of properties that match pattern using lodash


Is there any way using the lodash function to return an array of properties that match to a pattern?



_.magicMethod({a:'hi', b:13, c:undefined, d:null, e:null}, null)

return => `['d','e']`


I checked the docs but I don't found nothing :/ Thank you.





Aucun commentaire:

Enregistrer un commentaire