bennett000 / ch1-utility

Utility functions I end up using in all my projects

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

CH1 Utility

CircleCI

This is not well maintained

Installation

yarn add @ch1/utility

Interfaces

  • Dictionary<T>

Functions

  • arrToObj
  • createBetween (random: () => number) => () => number
  • deepFreeze
  • findCaseInsensitivePropInObj
  • hasProp
  • isBoolean
  • identity
  • isFunction
  • isNaN
  • isNumber
  • isNull
  • isObject
  • isString
  • isUndefined
  • noop
  • partial
  • pluck
  • objEach
  • objFilter
  • objReduce
  • toGtZeroIntMax
  • toInt
  • toIntArray
  • toIntArrayMax
  • toIntArrayMin
  • toIntBetweenOptional
  • toIntMax
  • toIntMin
  • toString
  • toStringArray
  • toStringArrayMax
  • toStringMax
  • unzip
  • zip
const between = createBetween(Math.random.bind(Math));
const randomNumber = between(0, 100); // inclusive due to Math.random

License

LGPL

About

Utility functions I end up using in all my projects

License:GNU Lesser General Public License v3.0


Languages

Language:TypeScript 100.0%