{"_id":"strsplit","_rev":"4251902","name":"strsplit","description":"split a string by a regular expression","dist-tags":{"latest":"1.0.0"},"maintainers":[{"name":"bahamat","email":""},{"name":"dap","email":""},{"name":"kebesays","email":""},{"name":"kusor","email":""},{"name":"michael.hicks","email":"michael.hicks@joyent.com"},{"name":"todd.whiteman","email":"todd.whiteman@joyent.com"},{"name":"tpaul","email":""}],"time":{"modified":"2026-03-31T23:47:09.000Z","created":"2012-07-19T03:36:33.604Z","1.0.0":"2012-07-30T21:05:36.697Z","0.0.1":"2012-07-19T03:36:33.604Z"},"users":{},"author":{"name":"Dave Pacheco","email":"dap@joyent.com"},"repository":{"type":"git","url":"https://github.com/davepacheco/node-strsplit"},"versions":{"1.0.0":{"name":"strsplit","version":"1.0.0","description":"split a string by a regular expression","main":"lib/strsplit.js","repository":{"type":"git","url":"https://github.com/davepacheco/node-strsplit"},"keywords":["string","split"],"author":{"name":"Dave Pacheco","email":"dap@joyent.com"},"license":"MIT","scripts":{"test":"make test"},"_id":"strsplit@1.0.0","dist":{"shasum":"0fdedc68e91addcfcb2e6be9c262581a6e8c28aa","size":12183,"noattachment":false,"key":"/strsplit/-/strsplit-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/strsplit/download/strsplit-1.0.0.tgz"},"maintainers":[{"name":"bahamat","email":""},{"name":"dap","email":""},{"name":"kebesays","email":""},{"name":"kusor","email":""},{"name":"michael.hicks","email":"michael.hicks@joyent.com"},{"name":"todd.whiteman","email":"todd.whiteman@joyent.com"},{"name":"tpaul","email":""}],"directories":{},"publish_time":1343682336697,"_hasShrinkwrap":false,"_cnpm_publish_time":1343682336697,"_cnpmcore_publish_time":"2021-12-16T23:06:44.648Z"},"0.0.1":{"name":"strsplit","version":"0.0.1","description":"split a string by a regular expression","main":"lib/strsplit.js","repository":{"type":"git","url":"https://github.com/davepacheco/node-strsplit"},"keywords":["string","split"],"author":{"name":"Dave Pacheco","email":"dap@joyent.com"},"license":"MIT","_id":"strsplit@0.0.1","dist":{"shasum":"3a32439ed12c84a63022f4463709c774820a50e6","size":8390,"noattachment":false,"key":"/strsplit/-/strsplit-0.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/strsplit/download/strsplit-0.0.1.tgz"},"maintainers":[{"name":"bahamat","email":""},{"name":"dap","email":""},{"name":"kebesays","email":""},{"name":"kusor","email":""},{"name":"michael.hicks","email":"michael.hicks@joyent.com"},{"name":"todd.whiteman","email":"todd.whiteman@joyent.com"},{"name":"tpaul","email":""}],"directories":{},"publish_time":1342668993604,"_hasShrinkwrap":false,"_cnpm_publish_time":1342668993604,"_cnpmcore_publish_time":"2021-12-16T23:06:44.853Z"}},"readme":"# node-strsplit: split a string by a regular expression\n\n## strsplit(str, pattern[, limit])\n\nSplits a string `str` into at most `limit` fields using the pattern `pattern` as\na delimeter.  The pattern may be either a string or a regular expression.  The\nreturned value is an array of fields.\n\nIf `limit` is unspecified or zero, any number of fields may be returned, and the\nbehavior is exactly identical to `str.split(pattern)`.\n\n`strsplit(str, pattern, limit)` behaves just like `str.split(pattern, limit)`,\nwith one important exception: the string is split at most `limit - 1` times,\nso the last returned element contains the contents of all subsequent fields.\nString.split truncates all such fields.\n\nBy comparison, here's String.split:\n\n    > 'alpha bravo charlie delta'.split(' ', 3)\n    [ 'alpha', 'bravo', 'charlie' ]\n\nand here's strsplit:\n\n    > strsplit('alpha bravo charlie delta', ' ', 3)\n    [ 'alpha', 'bravo', 'charlie delta' ]\n\nThis is the behavior implemented by `split` in Perl, Java, and other\nenvironments.\n","_attachments":{},"license":"MIT"}