{"_id":"starts-with","_rev":"96528","name":"starts-with","description":"Returns `true` if the given string or array starts with prefix using strict equality for comparisons. Using fastest implementation.","dist-tags":{"latest":"1.0.2"},"maintainers":[{"name":"npm:tunnckocore","email":""},{"name":"tunnckocore","email":"mameto_100@mail.bg"}],"time":{"modified":"2021-06-03T10:32:17.000Z","created":"2014-12-06T00:27:54.771Z","1.0.2":"2015-07-09T13:59:39.168Z","1.0.1":"2015-07-09T06:47:33.471Z","1.0.0":"2015-03-31T03:31:43.028Z","0.1.0":"2014-12-08T10:32:15.757Z","0.0.0":"2014-12-06T00:27:54.771Z"},"users":{},"author":{"name":"Charlike Mike Reagent","email":"@tunnckoCore","url":"http://www.tunnckocore.tk"},"repository":{"type":"git","url":"git+https://github.com/tunnckocore/starts-with.git"},"versions":{"1.0.2":{"name":"starts-with","version":"1.0.2","description":"Returns `true` if the given string or array starts with prefix using strict equality for comparisons. Using fastest implementation.","repository":{"type":"git","url":"git+https://github.com/tunnckocore/starts-with.git"},"author":{"name":"Charlike Mike Reagent","email":"@tunnckoCore","url":"http://www.tunnckocore.tk"},"main":"index.js","license":"MIT","scripts":{"test":"standard && node test.js"},"dependencies":{},"devDependencies":{"assertit":"^0.1.0","benchmarked":"^0.1.4","lodash.startswith":"^3.0.1"},"keywords":["array","begin","first","javascript","js","prefix","start","starts","string","tool","util","utility","utils"],"files":["index.js"],"standard":{"ignore":["benchmark/**/*.js"]},"gitHead":"98b9de85f66b10c153b6bf223d56d2ba441b8d8b","bugs":{"url":"https://github.com/tunnckocore/starts-with/issues"},"homepage":"https://github.com/tunnckocore/starts-with#readme","_id":"starts-with@1.0.2","_shasum":"16793a729d89d4cf3d4fb2eda2f908ae357f196f","_from":".","_npmVersion":"2.11.0","_nodeVersion":"2.2.1","_npmUser":{"name":"tunnckocore","email":"mameto_100@mail.bg"},"maintainers":[{"name":"npm:tunnckocore","email":""},{"name":"tunnckocore","email":"mameto_100@mail.bg"}],"dist":{"shasum":"16793a729d89d4cf3d4fb2eda2f908ae357f196f","size":3035,"noattachment":false,"key":"/starts-with/-/starts-with-1.0.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/starts-with/download/starts-with-1.0.2.tgz"},"directories":{},"publish_time":1436450379168,"_cnpm_publish_time":1436450379168,"_hasShrinkwrap":false},"1.0.1":{"name":"starts-with","version":"1.0.1","description":"Returns `true` if the given string or array starts with prefix using strict equality for comparisons. Using fastest implementation.","repository":{"type":"git","url":"git+https://github.com/tunnckocore/starts-with.git"},"author":{"name":"Charlike Mike Reagent","email":"@tunnckoCore","url":"http://www.tunnckocore.tk"},"main":"index.js","license":"MIT","scripts":{"test":"standard && node test.js"},"dependencies":{},"devDependencies":{"assertit":"^0.1.0","benchmarked":"^0.1.4","lodash.startswith":"^3.0.1"},"keywords":["array","begin","first","javascript","js","prefix","start","starts","string","tool","util","utility","utils"],"files":["index.js"],"standard":{"ignore":["benchmark/**/*.js"]},"gitHead":"e3fa8fa6490c74fc5cbc6965ceb818fffdb39077","bugs":{"url":"https://github.com/tunnckocore/starts-with/issues"},"homepage":"https://github.com/tunnckocore/starts-with#readme","_id":"starts-with@1.0.1","_shasum":"5582d805c5acca1f18088be4c8bdf790e88d7b60","_from":".","_npmVersion":"2.11.0","_nodeVersion":"2.2.1","_npmUser":{"name":"tunnckocore","email":"mameto_100@mail.bg"},"maintainers":[{"name":"npm:tunnckocore","email":""},{"name":"tunnckocore","email":"mameto_100@mail.bg"}],"dist":{"shasum":"5582d805c5acca1f18088be4c8bdf790e88d7b60","size":3006,"noattachment":false,"key":"/starts-with/-/starts-with-1.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/starts-with/download/starts-with-1.0.1.tgz"},"directories":{},"publish_time":1436424453471,"_cnpm_publish_time":1436424453471,"_hasShrinkwrap":false},"1.0.0":{"name":"starts-with","version":"1.0.0","description":"Returns `true` if the given string or array starts with prefix using strict equality for comparisons. Using fastest implementation from http://jsperf.com/starts-with-comparing-12-implementations","scripts":{"lint":"jshint index.js && jscs index.js --reporter inline","test":"lab -cv test.js","test-travis":"lab -cv test.js && lab -r lcov -o ./coverage/lcov.info test.js"},"author":{"name":"Charlike Mike Reagent","email":"mameto_100@mail.bg","url":"https://github.com/tunnckoCore"},"repository":{"type":"git","url":"git://github.com/tunnckoCore/starts-with.git"},"keywords":["array","start","starts","javascript","js","string","prefix","util","utility","utils","with"],"license":{"type":"MIT","url":"https://github.com/tunnckoCore/starts-with/blob/master/license.md"},"dependencies":{},"devDependencies":{"benchmarked":"~0.1.4","lodash.startswith":"~3.0.1","lab":"~5.5.1"},"gitHead":"8539a9e90ebe04700517e69dd03c1a66b64aa3de","bugs":{"url":"https://github.com/tunnckoCore/starts-with/issues"},"homepage":"https://github.com/tunnckoCore/starts-with","_id":"starts-with@1.0.0","_shasum":"f44344f9acfd2261113037d2bd63f43aad11068a","_from":".","_npmVersion":"2.7.0","_nodeVersion":"1.5.1","_npmUser":{"name":"tunnckocore","email":"mameto_100@mail.bg"},"maintainers":[{"name":"npm:tunnckocore","email":""},{"name":"tunnckocore","email":"mameto_100@mail.bg"}],"dist":{"shasum":"f44344f9acfd2261113037d2bd63f43aad11068a","size":6474,"noattachment":false,"key":"/starts-with/-/starts-with-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/starts-with/download/starts-with-1.0.0.tgz"},"directories":{},"publish_time":1427772703028,"_cnpm_publish_time":1427772703028,"_hasShrinkwrap":false},"0.1.0":{"name":"starts-with","description":"Returns `true` if the given string or array starts with prefix using strict equality for comparisons.","version":"0.1.0","scripts":{"lint":"npm install && node_modules/.bin/jshint . && node_modules/.bin/jscs . --reporter inline","test":"npm run lint && node_modules/.bin/mocha --require should","test-cov":"npm run lint && node_modules/.bin/istanbul cover node_modules/.bin/_mocha -- --require should","test-travis":"npm run lint && node_modules/.bin/istanbul cover node_modules/.bin/_mocha --report lcovonly -- --require should","coveralls":"npm run test-travis && cat coverage/lcov.info | node_modules/.bin/coveralls"},"author":{"name":"Charlike Make Reagent","email":"mameto_100@mail.bg","url":"https://github.com/tunnckoCore"},"keywords":["array","start","starts","javascript","js","string","prefix","util","utility","utils"],"repository":{"type":"git","url":"git://github.com/tunnckoCore/starts-with.git"},"license":{"type":"MIT","url":"https://github.com/tunnckoCore/starts-with/blob/master/license.md"},"dependencies":{},"devDependencies":{"should":"^4.3.0","coveralls":"^2.11.2","istanbul":"^0.3.5","jscs":">=1.8.0","jscs-jsdoc":">=0.2.0","jshint":"^2.5.10","mocha":"^2.0.1","mocha-lcov-reporter":"0.0.1"},"engines":{"node":">= 0.10.33","npm":">= 1.4.28"},"gitHead":"5b5e7df6e71f3681dbf716b97cadf7074701da1b","bugs":{"url":"https://github.com/tunnckoCore/starts-with/issues"},"homepage":"https://github.com/tunnckoCore/starts-with","_id":"starts-with@0.1.0","_shasum":"1623f95d3e85401db343a8f59d6cbd6ed10c0520","_from":".","_npmVersion":"2.0.0","_npmUser":{"name":"tunnckocore","email":"mameto_100@mail.bg"},"maintainers":[{"name":"npm:tunnckocore","email":""},{"name":"tunnckocore","email":"mameto_100@mail.bg"}],"dist":{"shasum":"1623f95d3e85401db343a8f59d6cbd6ed10c0520","size":5329,"noattachment":false,"key":"/starts-with/-/starts-with-0.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/starts-with/download/starts-with-0.1.0.tgz"},"directories":{},"publish_time":1418034735757,"_cnpm_publish_time":1418034735757,"_hasShrinkwrap":false},"0.0.0":{"name":"starts-with","version":"0.0.0","description":"wip","main":"index.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"keywords":["wip"],"author":"","license":"MIT","_id":"starts-with@0.0.0","_shasum":"5b8109d1af5cd3d73a67e14105b5d46db6329260","_from":".","_npmVersion":"2.0.0","_npmUser":{"name":"tunnckocore","email":"mameto_100@mail.bg"},"maintainers":[{"name":"npm:tunnckocore","email":""},{"name":"tunnckocore","email":"mameto_100@mail.bg"}],"dist":{"shasum":"5b8109d1af5cd3d73a67e14105b5d46db6329260","size":343,"noattachment":false,"key":"/starts-with/-/starts-with-0.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/starts-with/download/starts-with-0.0.0.tgz"},"directories":{},"publish_time":1417825674771,"_cnpm_publish_time":1417825674771,"_hasShrinkwrap":false}},"readme":"# [starts-with][author-www-url] [![npmjs.com][npmjs-img]][npmjs-url] [![The MIT License][license-img]][license-url] \n\n> Returns `true` if the given string or array starts with prefix using strict equality for comparisons. Using fastest implementation.\n\n[![code climate][codeclimate-img]][codeclimate-url] [![standard code style][standard-img]][standard-url] [![travis build status][travis-img]][travis-url] [![coverage status][coveralls-img]][coveralls-url] [![dependency status][david-img]][david-url]\n\n\n## Install\n```\nnpm i starts-with --save\nnpm test\n```\n\n\n## Usage\n> For more use-cases see the [tests](./test.js)\n\n```js\nvar startsWith = require('starts-with')\n\nstartsWith('abcdefghi', 'abcd') //=> true\nstartsWith(['abc', 'def', 'ghi'], 'abc') //=> true\nstartsWith(['abc', 'def', 'ghi'], ['abc']) //=> false\nstartsWith(['cab', 'cdf', 'cef'], 'c') //=> false\nstartsWith([57, 'a', 'b'], 57) //=> true\nstartsWith([57, 'a', 'b', 'c'], '57') //=> false\nstartsWith(['57', 'a', 'b', 'c'], '57') //=> true\n```\n\n\n## Related\n- [ends-with](https://github.com/jonschlinkert/ends-with): Returns `true` if the given `string` or `array` ends with `suffix` using strict equality for comparisons.\n- [each-string-index](https://github.com/jonschlinkert/each-string-index): Get the index for each occurrence of a string, in a string. Much faster than regex, and useful for doing simple find and replace operations for specific strings.\n- [starts-with-any](https://github.com/jonschlinkert/starts-with-any): Returns true if the given string or array begins with any of the given substrings.\n\n\n## Contributing\nPull requests and stars are always welcome. For bugs and feature requests, [please create an issue](https://github.com/tunnckoCore/starts-with/issues/new).  \nBut before doing anything, please read the [CONTRIBUTING.md](./CONTRIBUTING.md) guidelines.\n\n\n## [Charlike Make Reagent](http://j.mp/1stW47C) [![new message to charlike][new-message-img]][new-message-url] [![freenode #charlike][freenode-img]][freenode-url]\n\n[![tunnckocore.tk][author-www-img]][author-www-url] [![keybase tunnckocore][keybase-img]][keybase-url] [![tunnckoCore npm][author-npm-img]][author-npm-url] [![tunnckoCore twitter][author-twitter-img]][author-twitter-url] [![tunnckoCore github][author-github-img]][author-github-url]\n\n\n[npmjs-url]: https://www.npmjs.com/package/starts-with\n[npmjs-img]: https://img.shields.io/npm/v/starts-with.svg?label=starts-with\n\n[license-url]: https://github.com/tunnckoCore/starts-with/blob/master/LICENSE.md\n[license-img]: https://img.shields.io/badge/license-MIT-blue.svg\n\n\n[codeclimate-url]: https://codeclimate.com/github/tunnckoCore/starts-with\n[codeclimate-img]: https://img.shields.io/codeclimate/github/tunnckoCore/starts-with.svg\n\n[travis-url]: https://travis-ci.org/tunnckoCore/starts-with\n[travis-img]: https://img.shields.io/travis/tunnckoCore/starts-with.svg\n\n[coveralls-url]: https://coveralls.io/r/tunnckoCore/starts-with\n[coveralls-img]: https://img.shields.io/coveralls/tunnckoCore/starts-with.svg\n\n[david-url]: https://david-dm.org/tunnckoCore/starts-with\n[david-img]: https://img.shields.io/david/tunnckoCore/starts-with.svg\n\n[standard-url]: https://github.com/feross/standard\n[standard-img]: https://img.shields.io/badge/code%20style-standard-brightgreen.svg\n\n\n[author-www-url]: http://www.tunnckocore.tk\n[author-www-img]: https://img.shields.io/badge/www-tunnckocore.tk-fe7d37.svg\n\n[keybase-url]: https://keybase.io/tunnckocore\n[keybase-img]: https://img.shields.io/badge/keybase-tunnckocore-8a7967.svg\n\n[author-npm-url]: https://www.npmjs.com/~tunnckocore\n[author-npm-img]: https://img.shields.io/badge/npm-~tunnckocore-cb3837.svg\n\n[author-twitter-url]: https://twitter.com/tunnckoCore\n[author-twitter-img]: https://img.shields.io/badge/twitter-@tunnckoCore-55acee.svg\n\n[author-github-url]: https://github.com/tunnckoCore\n[author-github-img]: https://img.shields.io/badge/github-@tunnckoCore-4183c4.svg\n\n[freenode-url]: http://webchat.freenode.net/?channels=charlike\n[freenode-img]: https://img.shields.io/badge/freenode-%23charlike-5654a4.svg\n\n[new-message-url]: https://github.com/tunnckoCore/messages\n[new-message-img]: https://img.shields.io/badge/send%20me-message-green.svg\n","_attachments":{},"homepage":"https://github.com/tunnckocore/starts-with#readme","bugs":{"url":"https://github.com/tunnckocore/starts-with/issues"},"license":"MIT"}