- New
- accessibility
- browser
- sync
- Since 1.0.0
getDocumentDirection
Get the document direction (ltr or rtl) based on the current document.
- New
- random
- universal
- sync
- Since 1.0.4
getRandomInt
Get a random integer between min and max (inclusive).
- New
- validations
- universal
- sync
- Since 1.0.0
isFalsy
Checks if the value is falsy.
- New
- validations
- universal
- sync
- Since 1.0.0
hasValue
Checks if a value is truthy, meaning it is not falsy.
- New
- validations
- universal
- sync
- Since 1.0.0
isEmptyArray
Checks if an array is empty.
- New
- random
- universal
- sync
- Since 1.0.4
getRandomArrayItem
Get a random item from a given array.
- New
- random
- universal
- sync
- Since 1.0.4
getRandomFloat
Get a random floating-point number between min and max.
- New
- random
- universal
- sync
- Since 1.0.4
getRandomBoolean
Get a random boolean value (true or false).
- New
- random
- universal
- sync
- Since 1.0.4
getRandomBooleanArray
Get an array of randomized boolean values (true or false).
- New
- strings
- universal
- sync
- Since 1.0.4
slugify
Convert a string into a URL-friendly slug.
- New
- random
- browser
- sync
- Since 1.0.0
getRandomHexColor
Generate a random hexadecimal color.
- New
- arrays
- universal
- sync
- Since 1.0.0
chunk
Chunk an array into smaller arrays of a specified size.
- New
- arrays
- universal
- sync
- Since 1.0.0
groupBy
Groups the elements of an array based on a provided key-generating function.
- New
- arrays
- universal
- sync
- Since 1.0.0
limitArray
Limit an array to a certain number of elements and return the remaining count.
- New
- arrays
- universal
- sync
- Since 1.0.0
remove
Removes the element at the specified index from the array. This modifies the original array.
- New
- arrays
- universal
- sync
- Since 1.0.0
shuffle
Randomizes the order of elements in an array using the Fisher-Yates algorithm.
- New
- arrays
- universal
- sync
- Since 1.0.0
first
Returns the first element of an array.
- New
- arrays
- universal
- sync
- Since 1.0.0
last
Returns the last element of an array.
- New
- arrays
- universal
- sync
- Since 1.0.0
removeFirst
Removes the first element of an array.
- New
- arrays
- universal
- sync
- Since 1.0.0
removeLast
Removes the last element of an array.
- New
- validations
- browser
- sync
- Since 1.0.0
isClient
Checks if the code is running in the client-side (browser).
- New
- validations
- universal
- sync
- Since 1.0.0
isDeepKey
Checks if a given key is a deep key, containing a dot (.) or square brackets with a property accessor.
- New
- validations
- universal
- sync
- Since 1.0.0
isEqual
Compares two arrays for equality, checking if they have the same elements in the same order.
- New
- validations
- universal
- sync
- Since 1.0.0
isObject
Checks if the provided parameter is a plain object.
- New
- functions
- browser
- async
- Since 1.0.0
copyToClipboard
Copies the given text to the clipboard.
- New
- dates
- universal
- sync
- Since 1.0.0
daysBetween
Calculates the number of days between two dates.
- New
- functions
- browser
- async
- Since 1.0.1
encrypt
Encrypts a text using AES-GCM encryption algorithm.
- New
- functions
- browser
- async
- Since 1.0.0
decrypt
Decrypts a base64 encoded encrypted text using AES-GCM decryption algorithm.
- New
- functions
- universal
- async
- Since 1.0.0
sleep
Pauses the execution for a specified duration.
- New
- functions
- universal
- sync
- Since 1.0.0
debounce
Creates a debounced function that delays invoking the provided function until after the specified delay.
- New
- functions
- browser
- sync
- Since 1.0.0
getBrowserInfo
Returns information about the user's browser, including name, version, and user agent string.
- New
- random
- universal
- sync
- Since 1.0.4
pickRandom
Pick a specified number of random items from an array without repeating.
- New
- functions
- universal
- sync
- Since 1.0.0
uuid
Generates a random UUID (Universally Unique Identifier).
- New
- numbers
- universal
- sync
- Since 1.0.0
clamp
Clamps a number within the inclusive lower and upper bounds.
- New
- objects
- universal
- sync
- Since 1.0.0
cloneDeep
Deep clone an object. A deep clone is a clone of the source object and all of its children, and their children, and so on.
- New
- objects
- universal
- sync
- Since 1.0.0
getMainField
Retrieves the main field from an item object based on a predefined list of labels to highlight.
- New
- objects
- universal
- sync
- Since 1.0.0
merge
Merges the properties of the source object into the target object, performing a deep merge.
- New
- objects
- universal
- sync
- Since 1.0.0
isObjectLike
Checks if the value is an object (excluding null).
- New
- objects
- universal
- sync
- Since 1.0.0
mergeDeep
Merges and deep copies the values of all enumerable own properties of the target object from the source object to a new object.
- New
- objects
- universal
- sync
- Since 1.0.0
omit
Creates a new object with specified keys omitted.
- New
- objects
- universal
- sync
- Since 1.0.0
toPath
Converts a deep key string into an array of path segments.
- New
- parsers
- universal
- sync
- Since 1.0.0
parseJSON
A wrapper for 'JSON.parse()' to support 'undefined' value. If parsing fails, an error is thrown.
- New
- parsers
- universal
- sync
- Since 1.0.0
saveParseJson
A wrapper for 'JSON.parse()' to support 'undefined' value. If parsing fails, it silently returns 'undefined'.
- New
- dates
- universal
- sync
- Since 1.0.0
getTimeAgo
Returns a human-readable relative time string based on a given timestamp.
- New
- strings
- universal
- sync
- Since 1.0.0
px
Converts the specified number to a pixel string.
- New
- strings
- universal
- sync
- Since 1.0.0
toCamelCase
Converts a string to camel case.
- New
- strings
- universal
- sync
- Since 1.0.0
toTitleCase
Converts a string to title case.
- New
- strings
- universal
- sync
- Since 1.0.0
toKebabCase
Converts a string to kebab case.
- New
- strings
- universal
- sync
- Since 1.0.0
toUpperCase
Converts a string to upper case.
- New
- strings
- universal
- sync
- Since 1.0.0
toLowerCase
Converts a string to lower case.
- New
- strings
- universal
- sync
- Since 1.0.0
capitalize
Capitalizes the first letter of a string.
- New
- strings
- universal
- sync
- Since 1.0.0
removeWhitespace
Removes all whitespace from a string.
- New
- strings
- universal
- sync
- Since 1.0.0
reverseString
Reverses a string.
- New
- strings
- universal
- sync
- Since 1.0.0
truncateString
Truncates a string to a specified length.