Skip to content

TypeScript utility function that acts as an enhancement to the typeof operator by adding support for returning "array" and "null".

License

Notifications You must be signed in to change notification settings

codybonney/typeof-util

Repository files navigation

typeof-util

Build Status npm version

Description:

A simple TypeScript utility function that acts as an enhanced version of the typeof operator by adding support for returning "array" and "null". JavaScript UMD and TypeScript declaration file will be generated when building the package.

Installation:

npm install typeof-util

Usage:

import typeOf from 'typeof-util';

...

typeOf(true)  // 'boolean'
typeOf({})    // 'object'
typeOf([])    // 'array'
typeOf(null)  // 'null'

About

TypeScript utility function that acts as an enhancement to the typeof operator by adding support for returning "array" and "null".

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published