@finnn/type

0.0.3 • Public • Published

@Finnn/type

Check out object real type

Installation

npm install @finnn/type

Usage

const typeOf = require('@finnn/type') //with nodejs

or

import typeOf from '@finnn/type' //with webpack

Example:

typeOf(null),               // null
typeOf(()=>{}),             // function
typeOf(undefined),          // undefined
typeOf(new Set()),          // set
typeOf(new Map()),          // map
typeOf(new Date()),         // date
typeOf(new Array()),        // array
typeOf(new Error()),        // error
typeOf(new RegExp()),       // regexp
typeOf(new WeakMap()),      // weakmap
typeOf(new WeakSet()),      // weakset
typeOf(new Promise(() => {})),  // promise
typeOf(new ArrayBuffer()),      // arraybuffer
typeOf(new Int8Array()),        // int8array
typeOf(new Uint8Array()),       // uint8array
...

Readme

Keywords

Package Sidebar

Install

npm i @finnn/type

Weekly Downloads

1

Version

0.0.3

License

MIT

Unpacked Size

2.59 kB

Total Files

4

Last publish

Collaborators

  • finn.run