- Notifications
You must be signed in to change notification settings - Fork3
Filter an array of objects to a specific OS
License
NotificationsYou must be signed in to change notification settings
kevva/os-filter-obj
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Filter an array of objects to a specific OS
$ npm install os-filter-obj
constosFilterObj=require('os-filter-obj');constobjects=[{os:'linux',arch:'x64',foo:'unicorn',bar:'cow'},{os:'darwin',arch:'x64',foo:'unicorn',bar:'cow'},{os:'win32',arch:'x64',foo:'unicorn',bar:'cow'}];osFilterObj(objects);/*[{os: 'linux',arch: 'x64',foo: 'unicorn',bar: 'cow'}];*/
Returns anArray
with the filtered objects.
Type:Array
TheArray
to filter.
MIT ©Kevin Mårtensson
About
Filter an array of objects to a specific OS
Resources
License
Stars
Watchers
Forks
Packages0
No packages published