Type

Type module

Sources

Items from Type can be imported/included and used via following ways.

/**
 * --------------------------------------------------------
 * Import via main package: core.ts
 * Access items like: am5.type.myVariable
 *                    am5.type.myFunction()
 * --------------------------------------------------------
 */
import * as am5 from "@amcharts/amcharts4";

/**
 * --------------------------------------------------------
 * Import via: Type.ts
 * Access items like: $type.myVariable
 *                    $type.myFunction()
 * --------------------------------------------------------
 */
import * as $type from "@amcharts/amcharts5/Type";

/**
 * --------------------------------------------------------
 * Include via "index.js"
 * E.g.: "https://cdn.amcharts.com/lib/5/index.js"
 * Access items like: am5.type.myVariable
 *                    am5.type.myFunction()
 * --------------------------------------------------------
 */

Variables

Type does not have any variables.

Functions

isArray(

value: any

)

#

Returns value

Checks if parameter is Array.

isDate(

value: any

)

#

Returns value

Checks if parameter is Date.

isNaN(

value: number

)

#

Returns boolean

Returns true if value is not a number (NaN).

isNumber(

value: any

)

#

Returns value

Checks if parameter is number.

isObject(

value: any

)

#

Returns value

Checks if parameter is object.

isString(

value: any

)

#

Returns value

Checks if parameter is string.

numberToString(

value: number

)

#

Returns string

Converts numeric value into string. Deals with large or small numbers that would otherwise use exponents.

toDate(

value: Date | number | string

)

#

Returns Date

Converts anything to Date object.

toNumber(

value: any

)

#

Returns number

Converts any value into a number.