string-text-formatter
Format string text for seo friendly url slug, seo friendly url slug with unique id, random string generator
Install
$ npm install --save string-text-formatter
Usage
; // Remove all special characters and format string const str = 'What is Lorem Ipsum?'; // Lower Case Methodconst lowerCaseString = text; console;// what is lorem ipsum // Upper case Methodconst upperCaseString = text; console;// WHAT IS LOREM IPSUM // Convert space using any character Methodconst convertedString = text; console;// What_is_Lorem_Ipsum // Seo friendly url slug methodconst urlSlug = text; console;// what-is-lorem-ipsum // Seo friendly url slug with unique id methodconst urlSlugUnqiue = text; console;// what-is-lorem-ipsum-1555935965905 // Generate random string method// genetate alfhanumeric string /** * @params * length: total string length (Default 8) * allowSpecialCharacters: true / false*/ const string1 = text; console;// xg7IqOAqo97v const string2 = text; console;// _HNu19-C^ohH