pluckey - plucks key
A tiny util library to pluck key from deep arrays and objects
const pluckey = ; //sample objectlet college= class: student: 'name':'Vigneshwaran P' 'rollNo':'103' 'results': 'subject': 'Tamil' 'mark':99 'subject': 'Nodejs' 'mark':80 'name':'Bob' 'rollNo':'102' 'results': 'subject': 'English' 'mark':88 'subject': 'Nodejs' 'mark':89 ;//output=> [ 'Tamil', 'Nodejs', 'English', 'Nodejs' ] ; /*output=> [ { subject: 'Tamil', mark: 99 }, { subject: 'Nodejs', mark: 80 }, { subject: 'English', mark: 88 }, { subject: 'Nodejs', mark: 89 }]*/ ;//output=>[ 'Vigneshwaran P', 'Bob' ]
Installation
Installation is done using the
npm install
command:
$ npm install pluckey