@samuel-lewis/utils
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

@samuel-lewis/utils

A collection of various Javascript utilities.

Array

  • divide: Divides an array into two parts based on a given predicate
  • split: Given two arrays, finds their unique and intersecting values

Slug

  • toSlug: toSlug converts a string to a url safe slug
  • toUniqueSlug: toUniqueSlug does the same as toSlug, with addition of a unique ID

Time

  • seconds: Converts seconds to milliseconds
  • minutes: Converts minutes to milliseconds
  • hours: Converts hours to milliseconds
  • days: Converts days to milliseconds

Readme

Keywords

none

Package Sidebar

Install

npm i @samuel-lewis/utils

Weekly Downloads

0

Version

1.0.0

License

MIT

Unpacked Size

15.6 kB

Total Files

6

Last publish

Collaborators

  • samuel-lewis