Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/yumetodo/object-type-traits

type traits for js object
https://github.com/yumetodo/object-type-traits

Last synced: about 20 hours ago
JSON representation

type traits for js object

Awesome Lists containing this project

README

        

# object-type-traits

[![Build Status](https://travis-ci.org/yumetodo/object-type-traits.svg?branch=master)](https://travis-ci.org/yumetodo/object-type-traits)
[![Known Vulnerabilities](https://snyk.io/test/github/yumetodo/object-type-traits/badge.svg?targetFile=package.json)](https://snyk.io/test/github/yumetodo/object-type-traits?targetFile=package.json)
![license MIT](https://img.shields.io/badge/license-MIT-blue.svg)

A simple type checker like deprecated `jQuery.type`.

## Usage

```js
const type = require('object-type-traits');

console.log(type.of(32)); // => Number
console.log(type.isSame('String', 'foooo')); // => true
```