1.1.0 • Published 8 years ago
stb-guid v1.1.0
STB GUID
Returns a Globally Unique Identifier
GUID
GUID (or UUID) is an acronym for 'Globally Unique Identifier' (or 'Universally Unique Identifier'). It is a 128-bit integer number used to identify resources. The term GUID is generally used by developers working with Microsoft technologies, while UUID is used everywhere else.
How unique is a GUID?
128-bits is big enough and the generation algorithm is unique enough that if 1,000,000,000 GUIDs per second were generated for 1 year the probability of a duplicate would be only 50%. Or if every human on Earth generated 600,000,000 GUIDs there would only be a 50% probability of a duplicate.
Installation
npm install stb-guid
Use
var guid = require('stb-guid');
guid() // returns ex: cbb9a1d7-f048-4c3c-9add-d7018b0c9eaa
1.1.0
8 years ago