slug.js
v3.0.1
Published
Node.js package for slug string
Downloads
23
Readme
slug.js
Node.js package for slug string.
Prerequisites
Installation
npm install slug.js
Example
const Slug = require('slug.js');
const slug = new Slug();
(async () => {
try {
const slugify = await slug.slugify('asd 123 &@# abc');
console.log(slugify);
const slugifyArray = await slug.slugifyArray(['asdas @!# 123', '123 456 789 ABC DEF GHI']);
console.log(slugifyArray);
} catch (error) {
console.error(error);
}
})();