Skip to content

type

Signature

type(any)

Description

Returns the JavaScript type of the given argument as a string value.

Examples

type(`false`) == 'boolean'
type(null) == 'null'
type('foobar') == 'string'