1.0.0 • Published 8 years ago

arrays-difference v1.0.0

Weekly downloads
3
License
MIT
Repository
github
Last release
8 years ago

arrays-difference

Returns an array containing those elements which are present in first array and not in others

Installation

$ npm install arrays-difference

Usage

var arrDiff = require('arrays-difference');

arrDiff([1, 2], [2, 3, 4]);
//=> [1]

arrDiff([21, 27, 29, 31], [13, 4], [41, 27, 30], [21]);
//=> [29, 31]


arrDiff(['hello', 'world'], ['this', 'is', 'my', 'world']);
//=> ['hello']

License

MIT © Gaurav Luthra