Skip to content

Utility functions that is frequently used by me (Drstrain)

License

Notifications You must be signed in to change notification settings

phvietan/drutil

Repository files navigation

DrStrain utilities (drutil)

Utility functions that is frequently used by me (Drstrain) and has following features:

  • Zero dependency
  • Typescript supported
  • Over 90% test coverage
  • Over 20 common functionalities (random, sleep, read from user's input, crypto hash, hmac, log, etc)

Install

# using npm
npm install @drstrain/drutil

# using yarn
yarn add @drstrain/drutil

Documentations

https://stc.drstra.in/drutil/index.html

Example usage

Example usage of getRandomString:

import { getRandomString } from '@drstrain/drutil';

console.log(getRandomString(20));

Please check documentation for list of supported functions