brisky-stamp
Advanced tools
Comparing version 3.0.12 to 4.0.0
if (!global.briskystamp) { | ||
'use strict'; | ||
var exports$1 = {}; | ||
@@ -25,18 +26,4 @@ const ts = exports$1.ts = 535673248076; | ||
exports$1.create = (type, src, override) => { | ||
if (type) { | ||
return [ override || ms(), src || 0, parseInt(type, 36) ] | ||
} else if (src) { | ||
return [ override || ms(), src ] | ||
} else { | ||
return [ override || ms() ] | ||
} | ||
}; | ||
exports$1.create = override => override || ms(); | ||
exports$1.src = stamp => stamp && stamp[1]; | ||
exports$1.val = stamp => stamp && (stamp[0] || stamp); | ||
exports$1.type = stamp => stamp && stamp[2] && stamp[2].toString(36); | ||
exports$1.on = fn => { | ||
@@ -61,8 +48,3 @@ if (!on) { | ||
exports$1.parse = stamp => { | ||
const parsed = { val: stamp[0] }; | ||
const src = stamp[1]; | ||
const type = exports$1.type(stamp); | ||
if (src) parsed.src = src; | ||
if (type) parsed.type = type; | ||
return parsed | ||
return stamp > 1e6 ? (stamp + ts) : stamp | ||
}; | ||
@@ -69,0 +51,0 @@ } |
'use strict'; | ||
if (!global.briskystamp) { | ||
'use strict'; | ||
var exports$1 = {}; | ||
@@ -27,18 +28,4 @@ const ts = exports$1.ts = 535673248076; | ||
exports$1.create = (type, src, override) => { | ||
if (type) { | ||
return [ override || ms(), src || 0, parseInt(type, 36) ] | ||
} else if (src) { | ||
return [ override || ms(), src ] | ||
} else { | ||
return [ override || ms() ] | ||
} | ||
}; | ||
exports$1.create = override => override || ms(); | ||
exports$1.src = stamp => stamp && stamp[1]; | ||
exports$1.val = stamp => stamp && (stamp[0] || stamp); | ||
exports$1.type = stamp => stamp && stamp[2] && stamp[2].toString(36); | ||
exports$1.on = fn => { | ||
@@ -63,8 +50,3 @@ if (!on) { | ||
exports$1.parse = stamp => { | ||
const parsed = { val: stamp[0] }; | ||
const src = stamp[1]; | ||
const type = exports$1.type(stamp); | ||
if (src) parsed.src = src; | ||
if (type) parsed.type = type; | ||
return parsed | ||
return stamp > 1e6 ? (stamp + ts) : stamp | ||
}; | ||
@@ -71,0 +53,0 @@ } |
{ | ||
"name": "brisky-stamp", | ||
"version": "3.0.12", | ||
"version": "4.0.0", | ||
"description": "Generate unique meta information for change in a system", | ||
@@ -11,2 +11,3 @@ "main": "dist/index.js", | ||
"watch": "rollup -c -w", | ||
"dev-browser": "budo test/index.js --live", | ||
"prepublish": "npm run build", | ||
@@ -33,2 +34,3 @@ "pretest": "npm run build", | ||
"devDependencies": { | ||
"budo": "^9.4.5", | ||
"coveralls": "^2.11.9", | ||
@@ -35,0 +37,0 @@ "istanbul": "^0.4.3", |
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
10174
10
91