2.0.8 • Published 8 months ago

@winkgroup/misc v2.0.8

Weekly downloads
-
License
MIT
Repository
github
Last release
8 months ago

misc

Utility library used in WiNK for miscellaneous tasks

functions

  • timeFromNow: english text like "30 minutes ago", etc...
  • shrinkUrl: http://veryloooooooooongurl => http://sh...rturl
  • byteString: 123456789 => 123.5Mb
  • padZeros: padZeros(50, 3) => "050"
  • collapse: looooooong text => lo...xt
  • pickRandom: "1", "4", "8" => "4" (random)
  • camelToTitle: dontTryThisAtHome => Dont Try This At Home

extra functions available only on NodeJS (server side)

  • readline(question:string): to provide a question on the cli
  • getKeypress() => Promise: to read a key pressing in the cli
2.0.8

8 months ago

2.0.7

1 year ago

2.0.5

2 years ago

2.0.4

2 years ago

2.0.6

2 years ago

2.0.3

2 years ago

2.0.0

3 years ago

1.6.3

3 years ago

1.6.2

3 years ago

1.6.1

3 years ago

1.6.0

3 years ago

1.5.5

3 years ago

1.5.4

3 years ago

1.5.3

3 years ago

1.5.2

3 years ago

1.5.1

3 years ago

1.5.11

3 years ago

1.5.0

3 years ago