string-text-formatter
Advanced tools
Comparing version 1.0.5 to 1.0.6
@@ -1,1 +0,1 @@ | ||
{"/Users/soni/Documents/npm_repos/string-text-formatter/dist/index.js":{"path":"/Users/soni/Documents/npm_repos/string-text-formatter/dist/index.js","s":{"1":1,"2":1,"3":5,"4":5,"5":1,"6":1,"7":1,"8":1,"9":5,"10":1,"11":1,"12":5,"13":5,"14":1,"15":1,"16":1,"17":1,"18":5,"19":1,"20":1,"21":5,"22":5,"23":1,"24":1,"25":1,"26":1,"27":5,"28":1,"29":1,"30":5,"31":5,"32":1,"33":1,"34":1,"35":1,"36":1,"37":5,"38":1,"39":1,"40":5,"41":5,"42":1,"43":1,"44":1,"45":1,"46":1,"47":1,"48":1,"49":5,"50":1,"51":1,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":1},"b":{"1":[1,4],"2":[5,4,3],"3":[1,4],"4":[5,4,3],"5":[1,4],"6":[5,4,3],"7":[1,4],"8":[5,4,3],"9":[1,4],"10":[5,4,3],"11":[0,0]},"f":{"1":5,"2":5,"3":5,"4":5,"5":5,"6":0},"fnMap":{"1":{"name":"lowerCase","line":14,"loc":{"start":{"line":14,"column":0},"end":{"line":14,"column":24}}},"2":{"name":"upperCase","line":29,"loc":{"start":{"line":29,"column":0},"end":{"line":29,"column":24}}},"3":{"name":"convertString","line":45,"loc":{"start":{"line":45,"column":0},"end":{"line":45,"column":38}}},"4":{"name":"urlSlug","line":60,"loc":{"start":{"line":60,"column":0},"end":{"line":60,"column":22}}},"5":{"name":"urlSlugUnqiue","line":77,"loc":{"start":{"line":77,"column":0},"end":{"line":77,"column":28}}},"6":{"name":"randomString","line":96,"loc":{"start":{"line":96,"column":0},"end":{"line":96,"column":65}}}},"statementMap":{"1":{"start":{"line":5,"column":0},"end":{"line":5,"column":62}},"2":{"start":{"line":14,"column":0},"end":{"line":23,"column":1}},"3":{"start":{"line":15,"column":4},"end":{"line":15,"column":29}},"4":{"start":{"line":16,"column":4},"end":{"line":21,"column":5}},"5":{"start":{"line":17,"column":8},"end":{"line":17,"column":37}},"6":{"start":{"line":18,"column":8},"end":{"line":18,"column":72}},"7":{"start":{"line":19,"column":8},"end":{"line":19,"column":63}},"8":{"start":{"line":20,"column":8},"end":{"line":20,"column":56}},"9":{"start":{"line":22,"column":4},"end":{"line":22,"column":29}},"10":{"start":{"line":24,"column":0},"end":{"line":24,"column":30}},"11":{"start":{"line":29,"column":0},"end":{"line":38,"column":1}},"12":{"start":{"line":30,"column":4},"end":{"line":30,"column":29}},"13":{"start":{"line":31,"column":4},"end":{"line":36,"column":5}},"14":{"start":{"line":32,"column":8},"end":{"line":32,"column":37}},"15":{"start":{"line":33,"column":8},"end":{"line":33,"column":72}},"16":{"start":{"line":34,"column":8},"end":{"line":34,"column":63}},"17":{"start":{"line":35,"column":8},"end":{"line":35,"column":56}},"18":{"start":{"line":37,"column":4},"end":{"line":37,"column":29}},"19":{"start":{"line":39,"column":0},"end":{"line":39,"column":30}},"20":{"start":{"line":45,"column":0},"end":{"line":54,"column":1}},"21":{"start":{"line":46,"column":4},"end":{"line":46,"column":29}},"22":{"start":{"line":47,"column":4},"end":{"line":52,"column":5}},"23":{"start":{"line":48,"column":8},"end":{"line":48,"column":37}},"24":{"start":{"line":49,"column":8},"end":{"line":49,"column":72}},"25":{"start":{"line":50,"column":8},"end":{"line":50,"column":63}},"26":{"start":{"line":51,"column":8},"end":{"line":51,"column":68}},"27":{"start":{"line":53,"column":4},"end":{"line":53,"column":29}},"28":{"start":{"line":55,"column":0},"end":{"line":55,"column":38}},"29":{"start":{"line":60,"column":0},"end":{"line":70,"column":1}},"30":{"start":{"line":61,"column":4},"end":{"line":61,"column":29}},"31":{"start":{"line":62,"column":4},"end":{"line":68,"column":5}},"32":{"start":{"line":63,"column":8},"end":{"line":63,"column":37}},"33":{"start":{"line":64,"column":8},"end":{"line":64,"column":72}},"34":{"start":{"line":65,"column":8},"end":{"line":65,"column":63}},"35":{"start":{"line":66,"column":8},"end":{"line":66,"column":63}},"36":{"start":{"line":67,"column":8},"end":{"line":67,"column":56}},"37":{"start":{"line":69,"column":4},"end":{"line":69,"column":29}},"38":{"start":{"line":71,"column":0},"end":{"line":71,"column":26}},"39":{"start":{"line":77,"column":0},"end":{"line":89,"column":1}},"40":{"start":{"line":78,"column":4},"end":{"line":78,"column":29}},"41":{"start":{"line":79,"column":4},"end":{"line":87,"column":5}},"42":{"start":{"line":80,"column":8},"end":{"line":80,"column":61}},"43":{"start":{"line":81,"column":8},"end":{"line":81,"column":37}},"44":{"start":{"line":82,"column":8},"end":{"line":82,"column":72}},"45":{"start":{"line":83,"column":8},"end":{"line":83,"column":63}},"46":{"start":{"line":84,"column":8},"end":{"line":84,"column":63}},"47":{"start":{"line":85,"column":8},"end":{"line":85,"column":56}},"48":{"start":{"line":86,"column":8},"end":{"line":86,"column":60}},"49":{"start":{"line":88,"column":4},"end":{"line":88,"column":29}},"50":{"start":{"line":90,"column":0},"end":{"line":90,"column":38}},"51":{"start":{"line":96,"column":0},"end":{"line":109,"column":1}},"52":{"start":{"line":97,"column":4},"end":{"line":97,"column":16}},"53":{"start":{"line":98,"column":4},"end":{"line":103,"column":5}},"54":{"start":{"line":99,"column":8},"end":{"line":99,"column":112}},"55":{"start":{"line":102,"column":8},"end":{"line":102,"column":83}},"56":{"start":{"line":104,"column":4},"end":{"line":104,"column":31}},"57":{"start":{"line":105,"column":4},"end":{"line":107,"column":5}},"58":{"start":{"line":106,"column":8},"end":{"line":106,"column":75}},"59":{"start":{"line":108,"column":4},"end":{"line":108,"column":31}},"60":{"start":{"line":110,"column":0},"end":{"line":110,"column":36}}},"branchMap":{"1":{"line":16,"type":"if","locations":[{"start":{"line":16,"column":4},"end":{"line":16,"column":4}},{"start":{"line":16,"column":4},"end":{"line":16,"column":4}}]},"2":{"line":16,"type":"binary-expr","locations":[{"start":{"line":16,"column":8},"end":{"line":16,"column":34}},{"start":{"line":16,"column":38},"end":{"line":16,"column":50}},{"start":{"line":16,"column":54},"end":{"line":16,"column":71}}]},"3":{"line":31,"type":"if","locations":[{"start":{"line":31,"column":4},"end":{"line":31,"column":4}},{"start":{"line":31,"column":4},"end":{"line":31,"column":4}}]},"4":{"line":31,"type":"binary-expr","locations":[{"start":{"line":31,"column":8},"end":{"line":31,"column":34}},{"start":{"line":31,"column":38},"end":{"line":31,"column":50}},{"start":{"line":31,"column":54},"end":{"line":31,"column":71}}]},"5":{"line":47,"type":"if","locations":[{"start":{"line":47,"column":4},"end":{"line":47,"column":4}},{"start":{"line":47,"column":4},"end":{"line":47,"column":4}}]},"6":{"line":47,"type":"binary-expr","locations":[{"start":{"line":47,"column":8},"end":{"line":47,"column":34}},{"start":{"line":47,"column":38},"end":{"line":47,"column":50}},{"start":{"line":47,"column":54},"end":{"line":47,"column":71}}]},"7":{"line":62,"type":"if","locations":[{"start":{"line":62,"column":4},"end":{"line":62,"column":4}},{"start":{"line":62,"column":4},"end":{"line":62,"column":4}}]},"8":{"line":62,"type":"binary-expr","locations":[{"start":{"line":62,"column":8},"end":{"line":62,"column":34}},{"start":{"line":62,"column":38},"end":{"line":62,"column":50}},{"start":{"line":62,"column":54},"end":{"line":62,"column":71}}]},"9":{"line":79,"type":"if","locations":[{"start":{"line":79,"column":4},"end":{"line":79,"column":4}},{"start":{"line":79,"column":4},"end":{"line":79,"column":4}}]},"10":{"line":79,"type":"binary-expr","locations":[{"start":{"line":79,"column":8},"end":{"line":79,"column":34}},{"start":{"line":79,"column":38},"end":{"line":79,"column":50}},{"start":{"line":79,"column":54},"end":{"line":79,"column":71}}]},"11":{"line":98,"type":"if","locations":[{"start":{"line":98,"column":4},"end":{"line":98,"column":4}},{"start":{"line":98,"column":4},"end":{"line":98,"column":4}}]}}}} | ||
{"/Users/ajm/Documents/npm-packages/string-text-formatter/dist/index.js":{"path":"/Users/ajm/Documents/npm-packages/string-text-formatter/dist/index.js","s":{"1":1,"2":1,"3":5,"4":5,"5":1,"6":1,"7":1,"8":1,"9":5,"10":1,"11":1,"12":5,"13":5,"14":1,"15":1,"16":1,"17":1,"18":5,"19":1,"20":1,"21":5,"22":5,"23":1,"24":1,"25":1,"26":1,"27":5,"28":1,"29":1,"30":5,"31":5,"32":1,"33":1,"34":1,"35":1,"36":1,"37":5,"38":1,"39":1,"40":5,"41":5,"42":1,"43":1,"44":1,"45":1,"46":1,"47":1,"48":1,"49":5,"50":1,"51":1,"52":0,"53":0,"54":0,"55":0,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":1},"b":{"1":[1,4],"2":[5,4,3],"3":[1,4],"4":[5,4,3],"5":[1,4],"6":[5,4,3],"7":[1,4],"8":[5,4,3],"9":[1,4],"10":[5,4,3],"11":[0,0]},"f":{"1":5,"2":5,"3":5,"4":5,"5":5,"6":0},"fnMap":{"1":{"name":"lowerCase","line":14,"loc":{"start":{"line":14,"column":0},"end":{"line":14,"column":24}}},"2":{"name":"upperCase","line":29,"loc":{"start":{"line":29,"column":0},"end":{"line":29,"column":24}}},"3":{"name":"convertString","line":45,"loc":{"start":{"line":45,"column":0},"end":{"line":45,"column":38}}},"4":{"name":"urlSlug","line":60,"loc":{"start":{"line":60,"column":0},"end":{"line":60,"column":22}}},"5":{"name":"urlSlugUnqiue","line":77,"loc":{"start":{"line":77,"column":0},"end":{"line":77,"column":28}}},"6":{"name":"randomString","line":96,"loc":{"start":{"line":96,"column":0},"end":{"line":96,"column":65}}}},"statementMap":{"1":{"start":{"line":5,"column":0},"end":{"line":5,"column":62}},"2":{"start":{"line":14,"column":0},"end":{"line":23,"column":1}},"3":{"start":{"line":15,"column":4},"end":{"line":15,"column":29}},"4":{"start":{"line":16,"column":4},"end":{"line":21,"column":5}},"5":{"start":{"line":17,"column":8},"end":{"line":17,"column":37}},"6":{"start":{"line":18,"column":8},"end":{"line":18,"column":72}},"7":{"start":{"line":19,"column":8},"end":{"line":19,"column":63}},"8":{"start":{"line":20,"column":8},"end":{"line":20,"column":56}},"9":{"start":{"line":22,"column":4},"end":{"line":22,"column":29}},"10":{"start":{"line":24,"column":0},"end":{"line":24,"column":30}},"11":{"start":{"line":29,"column":0},"end":{"line":38,"column":1}},"12":{"start":{"line":30,"column":4},"end":{"line":30,"column":29}},"13":{"start":{"line":31,"column":4},"end":{"line":36,"column":5}},"14":{"start":{"line":32,"column":8},"end":{"line":32,"column":37}},"15":{"start":{"line":33,"column":8},"end":{"line":33,"column":72}},"16":{"start":{"line":34,"column":8},"end":{"line":34,"column":63}},"17":{"start":{"line":35,"column":8},"end":{"line":35,"column":56}},"18":{"start":{"line":37,"column":4},"end":{"line":37,"column":29}},"19":{"start":{"line":39,"column":0},"end":{"line":39,"column":30}},"20":{"start":{"line":45,"column":0},"end":{"line":54,"column":1}},"21":{"start":{"line":46,"column":4},"end":{"line":46,"column":29}},"22":{"start":{"line":47,"column":4},"end":{"line":52,"column":5}},"23":{"start":{"line":48,"column":8},"end":{"line":48,"column":37}},"24":{"start":{"line":49,"column":8},"end":{"line":49,"column":72}},"25":{"start":{"line":50,"column":8},"end":{"line":50,"column":63}},"26":{"start":{"line":51,"column":8},"end":{"line":51,"column":68}},"27":{"start":{"line":53,"column":4},"end":{"line":53,"column":29}},"28":{"start":{"line":55,"column":0},"end":{"line":55,"column":38}},"29":{"start":{"line":60,"column":0},"end":{"line":70,"column":1}},"30":{"start":{"line":61,"column":4},"end":{"line":61,"column":29}},"31":{"start":{"line":62,"column":4},"end":{"line":68,"column":5}},"32":{"start":{"line":63,"column":8},"end":{"line":63,"column":37}},"33":{"start":{"line":64,"column":8},"end":{"line":64,"column":72}},"34":{"start":{"line":65,"column":8},"end":{"line":65,"column":63}},"35":{"start":{"line":66,"column":8},"end":{"line":66,"column":63}},"36":{"start":{"line":67,"column":8},"end":{"line":67,"column":56}},"37":{"start":{"line":69,"column":4},"end":{"line":69,"column":29}},"38":{"start":{"line":71,"column":0},"end":{"line":71,"column":26}},"39":{"start":{"line":77,"column":0},"end":{"line":89,"column":1}},"40":{"start":{"line":78,"column":4},"end":{"line":78,"column":29}},"41":{"start":{"line":79,"column":4},"end":{"line":87,"column":5}},"42":{"start":{"line":80,"column":8},"end":{"line":80,"column":61}},"43":{"start":{"line":81,"column":8},"end":{"line":81,"column":37}},"44":{"start":{"line":82,"column":8},"end":{"line":82,"column":72}},"45":{"start":{"line":83,"column":8},"end":{"line":83,"column":63}},"46":{"start":{"line":84,"column":8},"end":{"line":84,"column":63}},"47":{"start":{"line":85,"column":8},"end":{"line":85,"column":56}},"48":{"start":{"line":86,"column":8},"end":{"line":86,"column":60}},"49":{"start":{"line":88,"column":4},"end":{"line":88,"column":29}},"50":{"start":{"line":90,"column":0},"end":{"line":90,"column":38}},"51":{"start":{"line":96,"column":0},"end":{"line":112,"column":1}},"52":{"start":{"line":97,"column":4},"end":{"line":97,"column":16}},"53":{"start":{"line":98,"column":4},"end":{"line":106,"column":5}},"54":{"start":{"line":99,"column":8},"end":{"line":99,"column":28}},"55":{"start":{"line":100,"column":8},"end":{"line":100,"column":87}},"56":{"start":{"line":101,"column":8},"end":{"line":101,"column":54}},"57":{"start":{"line":102,"column":8},"end":{"line":102,"column":29}},"58":{"start":{"line":105,"column":8},"end":{"line":105,"column":83}},"59":{"start":{"line":107,"column":4},"end":{"line":107,"column":31}},"60":{"start":{"line":108,"column":4},"end":{"line":110,"column":5}},"61":{"start":{"line":109,"column":8},"end":{"line":109,"column":75}},"62":{"start":{"line":111,"column":4},"end":{"line":111,"column":31}},"63":{"start":{"line":113,"column":0},"end":{"line":113,"column":36}}},"branchMap":{"1":{"line":16,"type":"if","locations":[{"start":{"line":16,"column":4},"end":{"line":16,"column":4}},{"start":{"line":16,"column":4},"end":{"line":16,"column":4}}]},"2":{"line":16,"type":"binary-expr","locations":[{"start":{"line":16,"column":8},"end":{"line":16,"column":34}},{"start":{"line":16,"column":38},"end":{"line":16,"column":50}},{"start":{"line":16,"column":54},"end":{"line":16,"column":71}}]},"3":{"line":31,"type":"if","locations":[{"start":{"line":31,"column":4},"end":{"line":31,"column":4}},{"start":{"line":31,"column":4},"end":{"line":31,"column":4}}]},"4":{"line":31,"type":"binary-expr","locations":[{"start":{"line":31,"column":8},"end":{"line":31,"column":34}},{"start":{"line":31,"column":38},"end":{"line":31,"column":50}},{"start":{"line":31,"column":54},"end":{"line":31,"column":71}}]},"5":{"line":47,"type":"if","locations":[{"start":{"line":47,"column":4},"end":{"line":47,"column":4}},{"start":{"line":47,"column":4},"end":{"line":47,"column":4}}]},"6":{"line":47,"type":"binary-expr","locations":[{"start":{"line":47,"column":8},"end":{"line":47,"column":34}},{"start":{"line":47,"column":38},"end":{"line":47,"column":50}},{"start":{"line":47,"column":54},"end":{"line":47,"column":71}}]},"7":{"line":62,"type":"if","locations":[{"start":{"line":62,"column":4},"end":{"line":62,"column":4}},{"start":{"line":62,"column":4},"end":{"line":62,"column":4}}]},"8":{"line":62,"type":"binary-expr","locations":[{"start":{"line":62,"column":8},"end":{"line":62,"column":34}},{"start":{"line":62,"column":38},"end":{"line":62,"column":50}},{"start":{"line":62,"column":54},"end":{"line":62,"column":71}}]},"9":{"line":79,"type":"if","locations":[{"start":{"line":79,"column":4},"end":{"line":79,"column":4}},{"start":{"line":79,"column":4},"end":{"line":79,"column":4}}]},"10":{"line":79,"type":"binary-expr","locations":[{"start":{"line":79,"column":8},"end":{"line":79,"column":34}},{"start":{"line":79,"column":38},"end":{"line":79,"column":50}},{"start":{"line":79,"column":54},"end":{"line":79,"column":71}}]},"11":{"line":98,"type":"if","locations":[{"start":{"line":98,"column":4},"end":{"line":98,"column":4}},{"start":{"line":98,"column":4},"end":{"line":98,"column":4}}]}}}} |
@@ -99,3 +99,6 @@ "use strict"; | ||
if (allowSpecialCharacters) { | ||
charset = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!#$%&()*+,-./:;<=>?@[\]^_{|}~'; | ||
let mixCharSet = ''; | ||
mixCharSet += 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'; | ||
mixCharSet += '!#$%&()*+,-./:;<=>?@[\]^_{|}~'; | ||
charset = mixCharSet; | ||
} | ||
@@ -102,0 +105,0 @@ else { |
{ | ||
"name": "string-text-formatter", | ||
"version": "1.0.5", | ||
"description": "Format string text for seo friendly url slug, seo friendly url slug with unique id, random string generator", | ||
"version": "1.0.6", | ||
"description": "Format string text for seo friendly url slug, seo friendly url slug with unique id, random string generator", | ||
"main": "dist/index.js", | ||
@@ -15,2 +15,3 @@ "scripts": { | ||
"author": "Mukesh Soni", | ||
"license": "MIT", | ||
"keywords": [ | ||
@@ -20,5 +21,12 @@ "format string text", | ||
"unique url slug", | ||
"random string" | ||
"generate random string" | ||
], | ||
"license": "MIT", | ||
"bugs": { | ||
"url": "https://github.com/mukeshsony/string-text-formatter/issues" | ||
}, | ||
"homepage": "https://github.com/mukeshsony/string-text-formatter#readme", | ||
"repository": { | ||
"type": "git", | ||
"url": "git+https://github.com/mukeshsony/string-text-formatter.git" | ||
}, | ||
"devDependencies": { | ||
@@ -25,0 +33,0 @@ "@types/chai": "^4.1.7", |
# string-text-formatter | ||
> Format string text for seo friendly url slug, seo friendly url slug with unique id, random string generator | ||
> Format string text for seo friendly url slug, seo friendly url slug with unique id, random string generator | ||
## Install | ||
@@ -64,4 +63,4 @@ | ||
// Generate random string method | ||
// genetate alfhanumeric string | ||
// genetate alfhanumeric string | ||
/** | ||
@@ -71,3 +70,3 @@ * @params | ||
* allowSpecialCharacters: true / false | ||
**/ | ||
*/ | ||
@@ -80,2 +79,3 @@ const string1 = text.randomString(12, false); | ||
const string2 = text.randomString(12, true); | ||
@@ -82,0 +82,0 @@ |
@@ -99,3 +99,6 @@ // ! index.js | ||
if (allowSpecialCharacters) { | ||
charset = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!#$%&()*+,-./:;<=>?@[\]^_{|}~'; | ||
let mixCharSet = ''; | ||
mixCharSet += 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'; | ||
mixCharSet += '!#$%&()*+,-./:;<=>?@[\]^_{|}~'; | ||
charset = mixCharSet; | ||
} else { | ||
@@ -102,0 +105,0 @@ charset = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'; |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Native code
Supply chain riskContains native code (e.g., compiled binaries or shared libraries). Including native code can obscure malicious behavior.
Found 1 instance in 1 package
No bug tracker
MaintenancePackage does not have a linked bug tracker in package.json.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
828
1
0
0
0
75041
20