, validates value is T
</td></tr>
[isEmpty(iterable)](/core3-utils/common.isempty.html)
|
Checks if an iterable is empty
|
[isErrorLikeObject(error)](/core3-utils/common.iserrorlikeobject.html)
|
Checks if the `error` is an object compatible with the Error interface; that is, it has properties 'name' and 'message' of type string. The object could be an instance of an Error, or it could be some other kind of object that has these properties.
|
[isIterable(x)](/core3-utils/common.isiterable.html)
|
|
[isMap(m)](/core3-utils/common.ismap.html)
|
Validates s is an instance of Map
|
[isObject(value)](/core3-utils/common.isobject.html)
|
Checks if value is an object, e.g. a plain object, an array, a function, a regex, but not a primitive value.
Common usage scenario:
```ts
isObject(value) && value.foo === 'bar';
// Instead of:
typeof value === 'object' && value !== null && 'foo' in value && value.foo === 'bar';
```
|
[isPlainObject(value)](/core3-utils/common.isplainobject.html)
|
Checks that value is a POJO
|
[isSet(s)](/core3-utils/common.isset.html)
|
Validates s is an instance of Set
|
[isString(value)](/core3-utils/common.isstring.html)
|
Checks is value is a string
|
[isValidNamingConvention(namingConvention)](/core3-utils/common.isvalidnamingconvention.html)
|
Checks if namingConvention is supported
|
[join(iterable, separator)](/core3-utils/common.join.html)
|
|
[keys(map)](/core3-utils/common.keys.html)
|
|
[keys(map)](/core3-utils/common.keys_1.html)
|
|
[last(iterable)](/core3-utils/common.last.html)
|
Picks the last element of an iterable
|
[map(iterable, mapFn)](/core3-utils/common.map.html)
|
Map iterable elements
|
[mapKeys(obj, mapping)](/core3-utils/common.mapkeys.html)
|
Maps values of a plain object
|
[mapObject(obj, mapping)](/core3-utils/common.mapobject.html)
|
Maps key value pairs of a plain object
|
[mapValues(obj, mapping)](/core3-utils/common.mapvalues.html)
|
Maps values of a plain object
|
[memoize(fn, argsHash)](/core3-utils/common.memoize.html)
|
|
[minimalIndent(str)](/core3-utils/common.minimalindent.html)
|
Shifts all indentation to the left using the line with the least indentation as a baseline
|
[mulberry32(a)](/core3-utils/common.mulberry32.html)
|
|
[newMacrotask()](/core3-utils/common.newmacrotask.html)
|
|
[next(iterable, item)](/core3-utils/common.next.html)
|
Find the element following an item
|
[noIdents(modified, separator)](/core3-utils/common.noidents.html)
|
Remove line indentation (heading whitespace)
|
[noop()](/core3-utils/common.noop.html)
|
|
[normToRage(normal, min, max)](/core3-utils/common.normtorage.html)
|
|
[noWhiteSpace(str)](/core3-utils/common.nowhitespace.html)
|
Remove white spaces including empty lines
|
[once(fn)](/core3-utils/common.once.html)
|
Make a function executable only once, following calls are ignored
|
[partition(data, bucketsCount, predicate)](/core3-utils/common.partition.html)
|
Partition unordered data into buckets of similar total weight
|
[pick(record, keys)](/core3-utils/common.pick.html)
|
returns an object composed of the picked object properties
|
[prev(iterable, item)](/core3-utils/common.prev.html)
|
Find the element before an item
|
[randomizedOrder(size)](/core3-utils/common.randomizedorder.html)
|
|
[reduce(iterable, reducer, initial)](/core3-utils/common.reduce.html)
|
|
[reportError\_2(ex)](/core3-utils/common.reporterror_2.html)
|
Logs an error
|
[reverseObject(obj)](/core3-utils/common.reverseobject.html)
|
Reverses keys-values of an object, ignoring falsy values. First takes on value collisions.
|
[same(a, b, unordered)](/core3-utils/common.same.html)
|
Deep comparison of two objects
|
[seededRandomInt(min, max)](/core3-utils/common.seededrandomint.html)
|
|
[shuffle(array)](/core3-utils/common.shuffle.html)
|
Shuffles an array
|
[size(iterable)](/core3-utils/common.size.html)
|
Evaluate the size of an iterable
|
[skip(iterable, count)](/core3-utils/common.skip.html)
|
Skips the first elements of an iterable
|
[some(iterable, predicate)](/core3-utils/common.some.html)
|
|
[sort(iterable, by)](/core3-utils/common.sort.html)
|
|
[splitIntoWords(str)](/core3-utils/common.splitintowords.html)
|
Breaks down a string to words, dropping non letters and numbers
|
[stringifyErrorStack(error)](/core3-utils/common.stringifyerrorstack.html)
|
|
[swap(array, i, j)](/core3-utils/common.swap.html)
|
Swaps elements of an array in place
|
[templateCompilerProvider(context)](/core3-utils/common.templatecompilerprovider.html)
|
Similar to templated string, given a fixed context object returns a function that parses strings in it
|
[toCamelCase(str)](/core3-utils/common.tocamelcase.html)
|
Converts a string to camelCase
|
[toCSSCamelCase(str)](/core3-utils/common.tocsscamelcase.html)
|
like [toCamelCase()](/core3-utils/common.tocamelcase.html), but capitalizes first character if input starts with '-'
|
[toCSSKebabCase(str)](/core3-utils/common.tocsskebabcase.html)
|
like [toKebabCase()](/core3-utils/common.tokebabcase.html), but prepends '-' if first character of input is UpperCase
|
[toError(value)](/core3-utils/common.toerror.html)
|
Convert any kind of value to an error instance. Unless the value is already an error instance, it's stringified and used as the error message.
|
[toKebabCase(str)](/core3-utils/common.tokebabcase.html)
|
Converts a string to kebab-case
|
[toMap(obj)](/core3-utils/common.tomap.html)
|
Coverts and object into a Map
|
[toNamingConvention(str, namingConvention)](/core3-utils/common.tonamingconvention.html)
|
Converts string formatting to a naming convention
|
[toPascalCase(str)](/core3-utils/common.topascalcase.html)
|
Converts a string to PascalCase
|
[toPascalCaseJsIdentifier(str)](/core3-utils/common.topascalcasejsidentifier.html)
|
Similar to [toPascalCase()](/core3-utils/common.topascalcase.html), but drops heading non-letters
|
[unique(iterable, by)](/core3-utils/common.unique.html)
|
Creates iterable of unique elements
|
[values(map)](/core3-utils/common.values.html)
|
|
[values(map)](/core3-utils/common.values_1.html)
|
|
</tbody></table>
## Variables
Variable
|
Description
|
[isElectronRendererProcess](/core3-utils/common.iselectronrendererprocess.html)
|
|
[isMac](/core3-utils/common.ismac.html)
|
|
[isWindows](/core3-utils/common.iswindows.html)
|
|
[remap](/core3-utils/common.remap.html)
|
remaps keys of obj based on rename map object,
|
## Type Aliases
Type Alias
|
Description
|
[Awaited\_2](/core3-utils/common.awaited_2.html)
|
The resolved value of T (if a promise, otherwise simply T)
|
[Chain](/core3-utils/common.chain.html)
|
|
[Flat](/core3-utils/common.flat.html)
|
|
[Iter](/core3-utils/common.iter.html)
|
|
[IterableChain](/core3-utils/common.iterablechain.html)
|
|
[Mapping](/core3-utils/common.mapping.html)
|
|
[MapValue](/core3-utils/common.mapvalue.html)
|
|
[NotIterable](/core3-utils/common.notiterable.html)
|
|
[Nullable](/core3-utils/common.nullable.html)
|
T or null/undefined
|
[ObjValue](/core3-utils/common.objvalue.html)
|
|
[Predicate](/core3-utils/common.predicate.html)
|
|
[Remap](/core3-utils/common.remap.html)
|
|
[RemapFunc](/core3-utils/common.remapfunc.html)
|
|
[Remapped](/core3-utils/common.remapped.html)
|
|
[UnionToIntersection](/core3-utils/common.uniontointersection.html)
|
Make an intersection type from union
|
[ValueChain](/core3-utils/common.valuechain.html)
|
|
[ValueOf](/core3-utils/common.valueof.html)
|
union of all fields of T
|