{"_id":"typeof-article","_rev":"80543","name":"typeof-article","description":"Get the native JavaScript type of a value, preceded by the appropriate indefinite article (either `a` or `an`), for use in error messages.","dist-tags":{"latest":"0.1.1"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"time":{"modified":"2021-06-03T10:25:44.000Z","created":"2017-01-29T21:31:41.564Z","0.1.1":"2017-01-30T06:08:35.403Z","0.1.0":"2017-01-29T21:31:41.564Z"},"users":{},"author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/typeof-article.git"},"versions":{"0.1.1":{"name":"typeof-article","description":"Get the native JavaScript type of a value, preceded by the appropriate indefinite article (either `a` or `an`), for use in error messages.","version":"0.1.1","homepage":"https://github.com/jonschlinkert/typeof-article","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/typeof-article.git"},"bugs":{"url":"https://github.com/jonschlinkert/typeof-article/issues"},"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=4"},"scripts":{"test":"mocha"},"keywords":["article","generategenerator","typeof"],"dependencies":{"kind-of":"^3.1.0"},"devDependencies":{"gulp-format-md":"^0.1.11","mocha":"^3.2.0"},"verb":{"toc":false,"layout":"default","tasks":["readme"],"plugins":["gulp-format-md"],"lint":{"reflinks":true}},"gitHead":"d9b741830246bbff51c503c50184cce509958a0b","_id":"typeof-article@0.1.1","_shasum":"9f07e733c3fbb646ffa9e61c08debacd460e06af","_from":".","_npmVersion":"3.10.9","_nodeVersion":"6.9.2","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"9f07e733c3fbb646ffa9e61c08debacd460e06af","size":2658,"noattachment":false,"key":"/typeof-article/-/typeof-article-0.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/typeof-article/download/typeof-article-0.1.1.tgz"},"_npmOperationalInternal":{"host":"packages-18-east.internal.npmjs.com","tmp":"tmp/typeof-article-0.1.1.tgz_1485756514846_0.06799974804744124"},"directories":{},"publish_time":1485756515403,"_cnpm_publish_time":1485756515403,"_hasShrinkwrap":false},"0.1.0":{"name":"typeof-article","description":"Get the native JavaScript type of a value, preceded by the appropriate indefinite article (either `a` or `an`), for use in error messages.","version":"0.1.0","homepage":"https://github.com/jonschlinkert/typeof-article","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git+https://github.com/jonschlinkert/typeof-article.git"},"bugs":{"url":"https://github.com/jonschlinkert/typeof-article/issues"},"license":"MIT","files":["index.js"],"main":"index.js","engines":{"node":">=4"},"scripts":{"test":"mocha"},"keywords":["article","generategenerator","typeof"],"dependencies":{"kind-of":"^3.1.0"},"devDependencies":{"gulp-format-md":"^0.1.11","mocha":"^3.2.0"},"verb":{"toc":false,"layout":"default","tasks":["readme"],"plugins":["gulp-format-md"],"lint":{"reflinks":true}},"gitHead":"d9b741830246bbff51c503c50184cce509958a0b","_id":"typeof-article@0.1.0","_shasum":"68f7e395a929b3d537d8353b8511b4fdab2d194f","_from":".","_npmVersion":"3.10.9","_nodeVersion":"6.9.2","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"}],"dist":{"shasum":"68f7e395a929b3d537d8353b8511b4fdab2d194f","size":2655,"noattachment":false,"key":"/typeof-article/-/typeof-article-0.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/typeof-article/download/typeof-article-0.1.0.tgz"},"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/typeof-article-0.1.0.tgz_1485725499628_0.5479982742108405"},"directories":{},"publish_time":1485725501564,"_cnpm_publish_time":1485725501564,"_hasShrinkwrap":false}},"readme":"# typeof-article [![NPM version](https://img.shields.io/npm/v/typeof-article.svg?style=flat)](https://www.npmjs.com/package/typeof-article) [![NPM monthly downloads](https://img.shields.io/npm/dm/typeof-article.svg?style=flat)](https://npmjs.org/package/typeof-article)  [![NPM total downloads](https://img.shields.io/npm/dt/typeof-article.svg?style=flat)](https://npmjs.org/package/typeof-article) [![Linux Build Status](https://img.shields.io/travis/jonschlinkert/typeof-article.svg?style=flat&label=Travis)](https://travis-ci.org/jonschlinkert/typeof-article)\n\n> Get the native JavaScript type of a value, preceded by the appropriate indefinite article (either `a` or `an`), for use in error messages.\n\n## Install\n\nInstall with [npm](https://www.npmjs.com/):\n\n```sh\n$ npm install --save typeof-article\n```\n\n## Usage\n\n_(A few of the types have some extra formatting where it makes sense. For example, instead of `a regexp`, it returns `a regular expression`, which IMHO is more readable to users. You can [customize mappings](#customize) if you want)_\n\n```js\nvar type = require('typeof-article');\n\nconsole.log(type({}));\n//=> 'an object'\n\nconsole.log(type([]));\n//=> 'an array'\n\nconsole.log(type(9));\n//=> 'a number'\n\nconsole.log(type(/abc/));\n//=> 'a regular expression'\n\nconsole.log(type(new WeakMap()));\n//=> 'a WeakMap'\n```\n\nGet the object of types-to-articles mappings:\n\n```js\nvar types = require('typeof-article').types;\n```\n\nAlso exposes a `typeOf` property, for getting the native type only:\n\n```js\nvar type = require('typeof-article');\ntype.types.weapmap = 'a WeakMap()';\n\nconsole.log(type.typeOf(new WeakMap()));\n//=> 'weakmap'\n```\n\n## Customize\n\nCustomize any of the mappings:\n\n```js\nvar type = require('typeof-article');\ntype.types.weapmap = 'a WeakMap()';\n\nconsole.log(type(new WeakMap()));\n//=> 'a WeakMap()'\n```\n\n## About\n\n### Contributing\n\nPull requests and stars are always welcome. For bugs and feature requests, [please create an issue](../../issues/new).\n\nPlease read the [contributing guide](.github/contributing.md) for advice on opening issues, pull requests, and coding standards.\n\n### Building docs\n\n_(This project's readme.md is generated by [verb](https://github.com/verbose/verb-generate-readme), please don't edit the readme directly. Any changes to the readme must be made in the [.verb.md](.verb.md) readme template.)_\n\nTo generate the readme, run the following command:\n\n```sh\n$ npm install -g verbose/verb#dev verb-generate-readme && verb\n```\n\n### Running tests\n\nInstall dev dependencies:\n\n```sh\n$ npm install && npm test\n```\n\n### Author\n\n**Jon Schlinkert**\n\n* [github/jonschlinkert](https://github.com/jonschlinkert)\n* [twitter/jonschlinkert](https://twitter.com/jonschlinkert)\n\n### License\n\nCopyright © 2017, [Jon Schlinkert](https://github.com/jonschlinkert).\nMIT\n\n***\n\n_This file was generated by [verb-generate-readme](https://github.com/verbose/verb-generate-readme), v0.4.2, on January 30, 2017._","_attachments":{},"homepage":"https://github.com/jonschlinkert/typeof-article","bugs":{"url":"https://github.com/jonschlinkert/typeof-article/issues"},"license":"MIT"}