{"_id":"typely","_rev":"5-45654f96927b730fe7d99eb6262fb658","name":"typely","description":"Lightweight (meaning relatively fast) type-checking in CoffeeScript. ","dist-tags":{"latest":"0.0.0"},"versions":{"0.0.0":{"name":"typely","version":"0.0.0","description":"Lightweight (meaning relatively fast) type-checking in CoffeeScript. ","main":"index.coffee","scripts":{"test":"coffee test.coffee"},"repository":{"type":"git","url":"git://github.com/dyoder/typely.git"},"keywords":["type-checking","coffeescript",""],"author":{"name":"Dan Yoder","email":"danielyoder@gmail.com"},"license":"MIT","readmeFilename":"README.md","dependencies":{"fairmont":"~0.4.1"},"readme":"# typely\n\nA lightweight (read: relatively fast) type-checking library in CoffeeScript.\n\n    {overload} = require \"typely\"\n\n    class Multiplier \n  \n      total: 1\n  \n      multiply: overload (match) ->\n        match \"array\", (array) -> @multiply element for element in array\n        match \"number\", (number) -> @total *= number\n    \n    multiplier = new Multiplier\n\n    multiplier.multiply 2\n    multiplier.multiply [ 3, 4, 5 ]\n\n    console.log multiplier.total\n    \nTypely is limited to checking for types, [as per Douglas Crockford's `typeOf` function][0]. That is: null, undefined, boolean, number, string, date, regexp, array, object, and function. This limitation allows it to run relatively fast, by simply using as an index a string based on the types of the given arguments and seeing whether it returns a function.\n\n## Installation\n\n    npm install typely","_id":"typely@0.0.0","dist":{"shasum":"cbb7cccd549febfff24f217d2186643c037d38e1","tarball":"https://registry.npmjs.org/typely/-/typely-0.0.0.tgz","integrity":"sha512-chtRLDVspVOkjK+ERP9TKCtB/tc61Dg/LEOTtUXuA3pj0xehnh3/3cJbJc3nzGX0OXu9nvYB2cnJvccZefhg2w==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCH3IHmkZDv3YfPGntzRqMEsTQRxdEYru9beqwdYpofGAIgNLpkFxVZJj37e8BYkafQQgT7GFJrKPunuFgDt+6BnaA="}]},"_npmVersion":"1.1.65","_npmUser":{"name":"dyoder","email":"danielyoder@gmail.com"},"maintainers":[{"name":"dyoder","email":"danielyoder@gmail.com"}]}},"readme":"# typely\n\nA lightweight (read: relatively fast) type-checking library in CoffeeScript.\n\n    {overload} = require \"typely\"\n\n    class Multiplier \n  \n      total: 1\n  \n      multiply: overload (match) ->\n        match \"array\", (array) -> @multiply element for element in array\n        match \"number\", (number) -> @total *= number\n    \n    multiplier = new Multiplier\n\n    multiplier.multiply 2\n    multiplier.multiply [ 3, 4, 5 ]\n\n    console.log multiplier.total\n    \nTypely is limited to checking for types, [as per Douglas Crockford's `typeOf` function][0]. That is: null, undefined, boolean, number, string, date, regexp, array, object, and function. This limitation allows it to run relatively fast, by simply using as an index a string based on the types of the given arguments and seeing whether it returns a function.\n\n## Installation\n\n    npm install typely","maintainers":[{"name":"dyoder","email":"danielyoder@gmail.com"}],"time":{"modified":"2022-06-28T01:44:23.185Z","created":"2013-06-01T02:00:42.240Z","0.0.0":"2013-06-01T02:00:43.224Z"},"author":{"name":"Dan Yoder","email":"danielyoder@gmail.com"},"repository":{"type":"git","url":"git://github.com/dyoder/typely.git"}}