/utils

Javascript utils

Primary LanguageTypeScript

Javascript utils

Install

npm install @ghom/utils

Usage

import "@ghom/utils"

Added methods

  • <RegExp>.matches() - returns an array of matches
  • <Array>.pick() - returns an array of objects with only the specified keys
  • <Array>.omit() - returns an array of objects without the specified keys
  • <Array>.partition() - return a tuple of two arrays, filtered by the predicate