mirror of
				https://github.com/flynx/types.js.git
				synced 2025-10-29 02:20:07 +00:00 
			
		
		
		
	Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
types.js
A library of JavaScript type extensions, types and type utilities.
Built-in type extenstions
Object
Object.deepKeys(..)
Object.match(..)
Object.matchPartial(..)
Object.flatCopy(..)
<object>.run(..)
Array
<array>.first(..) / <array>.last(..)
Get or set the first/last items of <array>.
<array>.compact()
Generate a compact <array> from a sparse <array>, i.e. removing all
the empty slots.
<array>.len
Number of non-empty slots/elements in <array>.
<array>.toKeys(..)
<array>.toMap(..)
<array>.unique(..) / <array>.tailUnique(..)
Generate an array with all duplicate elements removed.
<array>.cmp(..)
<array>.setCmp(..)
<array>.sortAs(..)
<array>.inplaceSortAs(..)
<array>.mapChunks(..)
<array>.filterChunks(..)
<array>.reduceChunks(..)
Array (polyfill)
<array>.flat()
<array>.includes()
Set
<set>.unite(..)
<set>.intersect(..)
<set>.subtract(..)
Date
Date.timeStamp(..)
Date.fromTimeStamp(..)
Date.str2ms(..)
<date>.toShortDate(..)
<date>.getTimeStamp(..)
<date>.setTimeStamp(..)
String
<string>.capitalize()
RegExp
RegExp.quoteRegExp(..)
Containers
UniqueKeyMap() (Map)
UniqueKeyMap extends the Map constructor.
XXX
For more info on Map see:
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map
<unique-key-map>.reset(..)
<unique-key-map>.uniqueKey(..)
<unique-key-map>.rename(..)
<unique-key-map>.keysOf(..)
			
		Description
				
					Languages
				
				
								
								
									JavaScript
								
								100%