cookie-getter
Advanced tools
Comparing version 0.0.2 to 1.0.0
// simple commonJS cookie reader, best perf according to http://jsperf.com/cookie-parsing | ||
module.exports = function (name) { | ||
var cookie = document.cookie, | ||
setPos = cookie.indexOf(name + '='), | ||
setPos = cookie.search(new RegExp('\\b' + name + '=')), | ||
stopPos = cookie.indexOf(';', setPos), | ||
@@ -6,0 +6,0 @@ res; |
@@ -5,4 +5,9 @@ { | ||
"description": "Super light, high performance clientside cookie reader. Common JS and clientmodules compatible.", | ||
"version": "0.0.2", | ||
"tags": ["cookie", "cookies", "client", "clientmodules"], | ||
"version": "1.0.0", | ||
"tags": [ | ||
"cookie", | ||
"cookies", | ||
"client", | ||
"clientmodules" | ||
], | ||
"repository": { | ||
@@ -12,3 +17,19 @@ "type": "git", | ||
}, | ||
"main": "./cookie-getter.js" | ||
"main": "./cookie-getter.js", | ||
"scripts": { | ||
"test": "node test/index.js | tap-spec", | ||
"lint": "jshint .", | ||
"validate": "npm ls" | ||
}, | ||
"devDependencies": { | ||
"jshint": "^2.5.3", | ||
"precommit-hook": "^3.0.0", | ||
"tap-spec": "^4.0.2", | ||
"tape": "^4.2.0" | ||
}, | ||
"pre-commit": [ | ||
"lint", | ||
"validate", | ||
"test" | ||
] | ||
} |
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
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
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
Trivial Package
Supply chain riskPackages less than 10 lines of code are easily copied into your own project and may not warrant the additional supply chain risk of an external dependency.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
2772
5
31
1
4