Socket
Socket
Sign inDemoInstall

consistent-ids

Package Overview
Dependencies
0
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    consistent-ids

A randomly consistent (a-la-Stripe) hash generator


Version published
Weekly downloads
91
increased by5.81%
Maintainers
1
Install size
14.1 kB
Created
Weekly downloads
 

Readme

Source

hash-generator

A no dependency randomly consistent (a-la-Stripe) hash generator

npm npm Travis branch Codecov branch
Commitizen friendly styled with prettier Code of Conduct Roadmap

Why?

// TODO

Installation

npm install consistent-ids --save 

Or use yarn (I ❤️ yarn)

yarn add consistent-ids

Usage


#In Your .env file
HASH_KEY = SomeTrulyRandomKeyWhichCannotBeGuessedByAnyone

import IdGenerator from 'consistent-ids';

const generator = new IdGenerator(); // We'll take care of HASH_KEY for you
generator.generate('ord');

// => ord_1BVVs21TuBY1vZhGhN03ug5
      
generator.generate('cus');

// => cus_1BVVs21TuBY1vZhGhN0sKqd

FAQ

What for ? To be written

Contributors

Maintainer


Clément SAUVAGE

Contributors

License

MIT © Clément SAUVAGE

Keywords

FAQs

Last updated on 22 May 2021

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc