Skip to content

10uei011/node-slugify

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

node-slugify

Build Status Coverage Status

A simple function which generates friendly url or slugs from string input.

Installing

npm i --save node-slugify

Usage

var slugify = require('node-slugify');

console.log(slugify('why is india a great country'));
// returns 'why-is-india-a-great-country'

console.log(slugify('Why is INDIA a great country', { maintainCase: true} ));
// returns 'Why-is-INDIA-a-great-country'

console.log(slugify('why is india a great country'), { replacement: '_'});
// returns 'why_is_india_a_great_country'

Tests

Run npm test

About

No description or website provided.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published