{"name":"slugg","version":"0.1.0","description":"Make strings url safe (with no dependencies)","keywords":["slug","url","string"],"main":"slugg.js","scripts":{"test":"./node_modules/.bin/mocha test -R spec"},"devDependencies":{"mocha":"~1.7"},"repository":{"type":"git","url":"git@github.com:bengourley/slugg.git"},"author":{"name":"Ben Gourley"},"license":"BSD","_id":"slugg@0.1.0","dist":{"shasum":"19d4f88ffb72d848f2cfe301e5963ae41a6ec827","tarball":"http://registry-npm.ywwl.com/slugg/download/slugg-0.1.0.tgz","integrity":"sha512-qvSTW4MZrelDBiqRGABQWHSOrsi0ugdH9ZFIxdrY/6mOGE/FvMPPUV3s88Oe8BnG48p9rElhXlWpkmpnT/mRdw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFv6wrvVHqSB9xcVoFezOxHNshdGKiDDjlL50sKEyRhcAiEA0MFars8rLLUcwbCrefsi93M+DzmhBYbUh0rcCxO+ZD0="}],"size":3281,"noattachment":false,"key":"/slugg/-/slugg-0.1.0.tgz"},"_from":".","_npmVersion":"1.2.17","_npmUser":{"name":"bengourley","email":"bn@grly.me"},"maintainers":[{"name":"bengourley","email":"benleighgourley@gmail.com"}],"directories":{},"readme":"# Slugg\n\nMake strings url-safe.\n\n- Comprehensive tests\n- No dependencies\n- Not in coffee-script (lol)\n- Coerces foreign symbols to their english equivalent\n- Doesn't try to do anything fancy with symbols (just removes them)\n- Works in browser (`window.slugg`) and AMD/CommonJS-flavoured module loaders\n\n```\nnpm install slugg\n```\n\n## Usage:\n\n### slug(string, [separator, toStrip])\n\n```js\nvar slug = require('slugg')\n\nslug('My fantastic blog post')\n//-> 'my-fantastic-blog-post'\n\nslug('Today I found £5')\n//-> 'today-i-found-5'\n\nslug('I ♥ you')\n//-> 'i-you'\n```\n\nIf you want a separator other than '-', pass it in as the second argument:\n\n```js\nslug('Kevin Spacey', ' ')\n//-> 'kevin spacey'\n```\n\nBy default, slugg will strip (i.e. remove and not replace) any sort of quotemark: `'\"’‘”“`.\n\nIf you want to control which characters are stripped, pass a regex as the last option\nthat will match the chars you want to replace, eg:\n\n```js\nslug('Mum\\'s cooking', /'/g)\n//-> 'mums-cooking'\n```\n\nRemember to use the `g` flag if you want all the matches stripped (not just the first).\n\nAfter version 1.1.0, a new syntax has been introduced:\n\n### slug(string, [options])\n\nIf you want a separator other than '-', pass it in as the `separator` option:\n\n```js\nslug('Kevin Spacey', { separator: ' ' })\n//-> 'kevin spacey'\n```\n\nIf you want to control which characters are stripped, pass a regex as the `toStrip` option\nthat will match the chars you want to replace, eg:\n\n```js\nslug('Mum\\'s cooking', { toStrip: /'/g })\n//-> 'mums-cooking'\n```\nRemember to use the `g` flag if you want all the matches stripped (not just the first).\n\nBy default, slugg will convert your string to lower case. If you want to disable it just\npass the `toLowerCase` option as `false`, eg:\n\n```js\nslug('Slugg rocks!', { toLowerCase: false })\n//-> 'Slugg-rocks'\n```\n","publish_time":1366629647228,"_cnpm_publish_time":1366629647228,"dist-tags":{"latest":"1.2.1"}}