My set of JS modules.
Return a new randomly ordered array based on an old one.
(Based on algorithm invented by Ronald Fisher and Frank Yates)
Usage:
- Import, or just copy and paste script to your project.
;[0, 1, 2, 3, 4, 5, 6, 7, 8, 9].shuffle() // return shuffle array
Convert to uppercase first letter of every word.
Usage:
- Import, or just copy and paste script to your project.
'havE a nIce dAy'.toCapitalize() // return "Have A Nice Day"
Parse '10/01/2017' to 'martes, 10 de enero de 2017'
Usage:
- Import, or just copy and paste script to your project.
const longDate = toLongDate('10/01/2017') // return 'martes, 10 de enero de 2017'