Skip to content

isPrimitive

Basic usage

Checks if the given value is primitive.

Primitive Types: number , string , boolean , symbol, bigint, undefined, null

import { isPrimitive } from 'radash'
isPrimitive(22) // => true
isPrimitive('hello') // => true
isPrimitive(['hello']) // => false