-
install with
npm install --save js-contains
-
remember to
require
the plugin -
example:
require('js-contains'); ["hi","ho"].contains("hi") // true ["he","ho"].contains("hi") // false "asjasdhiasdasd".contains("hi") // true "asjasdhoasdasd".contains("hi") // false
-
install with
bower install --save js-contains
-
inject the
js-contains.js
file into your HTML:<script src="[path_to_bower_packages]/js-contains/js-contains.js"></script>
-
example:
["hi","ho"].contains("hi") // true ["he","ho"].contains("hi") // false "asjasdhiasdasd".contains("hi") // true "asjasdhoasdasd".contains("hi") // false