slug-factory
v0.1.0
Published
Unique slug generator for node.js
Downloads
3
Maintainers
Readme
slug-factory
Unique Slug Generator for node.js.
Installation
npm install slug-factory
Usage
var slugFactory = require('slug-factory');
var exists = 4;
function iterator(path, cb) {
exists--;
cb(null, exists);
}
slugFactory('Slugen ips³ón.', iterator, function(err, slug) {
console.log(slug); // slugen-ipson-3
});
Test
mocha
Cheers.