canonical
Version:
Canonical code style linter and formatter for JavaScript, SCSS, CSS and JSON.
46 lines (32 loc) • 1.41 kB
Markdown
# is-js-type
[](https://badge.fury.io/js/is-js-type) [](https://travis-ci.org/dustinspecker/is-js-type) [](https://coveralls.io/r/dustinspecker/is-js-type?branch=master)
[](https://codeclimate.com/github/dustinspecker/is-js-type) [](https://david-dm.org/dustinspecker/is-js-type/#info=dependencies&view=table) [](https://david-dm.org/dustinspecker/is-js-type/#info=devDependencies&view=table)
> Is string a JS Type
**Uses [Sindre Sorhus](https://github.com/sindresorhus)' [js-types](https://github.com/sindresorhus/js-types)**
## Install
```
npm install --save is-js-type
```
## Usage
### ES2015
```javascript
import isJsType from 'is-js-type';
isJsType('array');
// => true
isJsType('Error');
// => true
isJsType('dog');
// => false
```
### ES5
```javascript
var isJsType = require('is-js-type');
isJsType('array');
// => true
isJsType('Error');
// => true
isJsType('dog');
// => false
```
## LICENSE
MIT © [Dustin Specker](https://github.com/dustinspecker)