README
@adico/sequencegenerator
Time Sortable Distributed Unique Id Generator based on Twitter Snowflake
Usage
API
Install locally npm install --save @adico/sequencegenerator
, then use like so:
import SequenceGenerator from '@adico/sequencegenerator'
// Generate Unique Id based on NodeId as hashed MAC address
console.log(new SequenceGenerator(254).nextId())
Advanced
Install
- Install:
npm install --save @adico/sequencegenerator
- Import:
import * as pkg from ('@adico/sequencegenerator')
- Require:
const pkg = require('@adico/sequencegenerator')
Editions
This package is published with the following editions:
@adico/sequencegenerator
aliases@adico/sequencegenerator/index.js
which uses the Editions Autoloader to automatically select the correct edition for the consumer's environment@adico/sequencegenerator/src/index.ts
is TypeScript source code with Import for modules@adico/sequencegenerator/edition-esnext/index.js
is TypeScript compiled against ESNext for Node.js with Require for modules@adico/sequencegenerator/edition-es5/index.js
is TypeScript compiled against ES5 for Node.js with Require for modules
History
Discover the release history by heading on over to the HISTORY.md
file.
Contribute
Discover how you can contribute by heading on over to the CONTRIBUTING.md
file.
Backers
Maintainers
These amazing people are maintaining this project:
Sponsors
No sponsors yet! Will you be the first?
Contributors
These amazing people have contributed code to this project:
Discover how you can contribute by heading on over to the CONTRIBUTING.md
file.
License
Unless stated otherwise all works are:
- Copyright © 2019+ adico
and licensed under: