A find and match utility. Search for a string or an array of strings within a string or array or strings.
Getting started
Install the module with: npm install haystack --save
var haystack = ;
Interface
filter
Creates an array of unique values present in all provided arrays using strict equality for comparisons, i.e. ===
.
haystack;// => [1, 2] haystack;// => ['a'] haystack;// => ['a'] haystack;// => ['c', 'd'] haystack;// => [] haystack;// => ['f']
Optionally pass a string separator as a third parameter.
haystack;// => ['f'] haystack;// => ['find']
hasMatch
haystack;// => true haystack;// => true haystack;// => true haystack;// => false haystack;// => true
Contributing
Find a bug? Have a feature request? Please create an Issue.
In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using grunt, and build the documentation with grunt-readme.
Pull requests are also encouraged, and if you find this project useful please consider "starring" it to show your support! Thanks!
Related projects
- helpers/resolve-dep
- helpers/matchkeys
- assemble/assemble
- assemble/assemble-less
- assemble/handlebars-helpers
Authors
Jon Schlinkert
License
Copyright (c) 2014 Jon Schlinkert, contributors. Released under the MIT license
This file was generated by grunt-readme on Wednesday, January 8, 2014.