{"_id":"@abhaydgarg/is","_rev":"5-0f0faf9a390f3d874fadcfa8fb0d6163","name":"@abhaydgarg/is","dist-tags":{"latest":"1.1.0"},"versions":{"0.1.0":{"name":"@abhaydgarg/is","version":"0.1.0","keywords":["type","types","check","checking","verify","is"],"author":{"name":"Abhay Garg"},"license":"MIT","_id":"@abhaydgarg/is@0.1.0","maintainers":[{"name":"abhaydgarg","email":"abhaydgarg@gmail.com"}],"homepage":"https://github.com/abhaydgarg/is.js#readme","bugs":{"url":"https://github.com/abhaydgarg/is.js/issues"},"dist":{"shasum":"89c262dddd2d2778c13f04f8598301cf00bccd46","tarball":"https://registry.npmjs.org/@abhaydgarg/is/-/is-0.1.0.tgz","fileCount":42,"integrity":"sha512-L8Dy9wZlzNZZZiBX6PESGtda29roM+qqQGdkvrqAf6Ydul98kS5HYSsM5gShJATwuiRmFTy1c0zqPj9gQOyEWg==","signatures":[{"sig":"MEUCIQDwRNcvbg2pL/lPSzd3XjlHnC8rOKdGaa8NbFbIJsZbVgIgBrM4S3m8BYYfVlFnpmofw71ZPL5oT/B+ok2AhagMN5o=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":19610},"main":"index.js","gitHead":"cc3710cc34cae08a243206e84512d52f6ca72bde","scripts":{"test":"./node_modules/mocha/bin/mocha test","test-file":"./node_modules/mocha/bin/mocha test/$FILE"},"_npmUser":{"name":"abhaydgarg","email":"abhaydgarg@gmail.com"},"repository":{"url":"git+https://github.com/abhaydgarg/is.js.git","type":"git"},"_npmVersion":"5.6.0","description":"Javascript checking library","directories":{},"_nodeVersion":"9.5.0","_hasShrinkwrap":false,"devDependencies":{"chai":"^4.1.2","mocha":"^5.0.0","eslint":"^4.17.0"},"_npmOperationalInternal":{"tmp":"tmp/is_0.1.0_1518515343528_0.11962709949321293","host":"s3://npm-registry-packages"}},"1.0.0":{"name":"@abhaydgarg/is","version":"1.0.0","keywords":["type","types","check","checking","verify","is"],"author":{"name":"Abhay Garg"},"license":"MIT","_id":"@abhaydgarg/is@1.0.0","maintainers":[{"name":"abhaydgarg","email":"abhaydgarg@gmail.com"}],"homepage":"https://github.com/abhaydgarg/is.js#readme","bugs":{"url":"https://github.com/abhaydgarg/is.js/issues"},"dist":{"shasum":"4a8faba88ea5a3fbd9028f730163b447ef32ee14","tarball":"https://registry.npmjs.org/@abhaydgarg/is/-/is-1.0.0.tgz","fileCount":42,"integrity":"sha512-nmxEa54E5sSPbpLcK/iOxkaAfsa/VyxnsENsv/FBdNwnsrQY8+nZJv5MnzabsJFUmet4Ap0r8+0m34HTgW3QGQ==","signatures":[{"sig":"MEUCIDTPm/tjMQma0X6kX/8PsDzv+WxZWCqC44NrmfNntp++AiEApwycKFpF7IUjcLA+PQyahhrttebQpgY0gSE12glRND8=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":18795},"main":"index.js","gitHead":"2f4e0f0e3cb98419089bee2366e4fc542b256037","scripts":{"test":"./node_modules/mocha/bin/mocha test","test-file":"./node_modules/mocha/bin/mocha test/$FILE"},"_npmUser":{"name":"abhaydgarg","email":"abhaydgarg@gmail.com"},"repository":{"url":"git+https://github.com/abhaydgarg/is.js.git","type":"git"},"_npmVersion":"5.6.0","description":"Javascript checking library","directories":{},"_nodeVersion":"9.5.0","_hasShrinkwrap":false,"devDependencies":{"chai":"^4.1.2","mocha":"^5.0.1","eslint":"^4.17.0"},"_npmOperationalInternal":{"tmp":"tmp/is_1.0.0_1518630881481_0.29092867586788107","host":"s3://npm-registry-packages"}},"1.1.0":{"name":"@abhaydgarg/is","version":"1.1.0","keywords":["type","types","check","checking","verify","is"],"author":{"name":"Abhay Garg"},"license":"MIT","_id":"@abhaydgarg/is@1.1.0","maintainers":[{"name":"abhaydgarg","email":"abhaydgarg@gmail.com"}],"homepage":"https://github.com/abhaydgarg/is.js#readme","bugs":{"url":"https://github.com/abhaydgarg/is.js/issues"},"dist":{"shasum":"d293def4cfff751740f793aec71f0e9f4ce54667","tarball":"https://registry.npmjs.org/@abhaydgarg/is/-/is-1.1.0.tgz","fileCount":51,"integrity":"sha512-I0sfQF1bapAwiiAj0Ok5io8UIvSHRTHqC9Rj/3cUj1ziaRMkKGHZSMCeR/vABllLhJVLNrcPPXP59T1Kr/AXoA==","signatures":[{"sig":"MEUCIQCESQi+cEFLtXRtSaQK9E4om9E0jISY276/kun10Vn5DQIgH0UITxJZipD/U23TVPYO9vUhjrkHymOc9e1VjI4Yv5c=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":23074,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbYCa9CRA9TVsSAnZWagAAGecP/0GxO/RQMIDWIpx/qOLf\nQ6MdVw+5JKxSPq0n5gKRk0O14X0u4b4ZxpQEiQl5yQpZTYbcJOGajxW+a4Kc\naYOcG/gIn+dyFUoekmx7tSB/ilZkV3uzsTiKoc+kWcv2zM/Cb3X6r7Y5kPZ4\nnbvndl3Zyey6z9gVaEMtnJtLJ0ZsW3D5DxbXSFIVkosEpo0cNtrHzb5Wyhix\nfq9zQ96WxZr8/xSovHRT+GJ2b1tD6etvEwU/UEgh8He3x+6Gv+Q+wP4hZuOT\nKukj1GiS5FIupIEoP8F/rB+xySHIevemsUocfdWY5Khfhc49xjPekaXzuVfn\nGf8pxkgbkG4PqTyLJFFgyUa1lCRr21yVoyZXpM6NtQY2efSERFz0SqBTUsY5\nxSZyh7U9yzhYR2tpT49NceTzO80quW3NHXhTZzh3KJNZwg0Kt9yMvW/pWFg/\noaZcDjkgdAWKbwqSjVVN5DrIUZTjHvU+/SOBfwhCZ98P9JI1M0yYoIqB6Q0s\nKodE5KTRgwap6E0zZoceHbjTIx9wZWRG415EdMTtven35tNFmKakvofbay5x\nUnSqzRf98I2vt/9DVhTi61grV6mx42CMrpQurjwrPYsF0q7tLPARaG0sEFyF\nWuoUzwQb4TxFrK/wIMiCnZLfFo7F1G9s8uOtIU1kmfgUy1ozblolkP2j2J2e\nvcr5\r\n=iKIb\r\n-----END PGP SIGNATURE-----\r\n"},"main":"index.js","gitHead":"583ee2d5a281de68ddab1d032a9065543a677e9c","scripts":{"test":"./node_modules/mocha/bin/mocha test","test:file":"./node_modules/mocha/bin/mocha test/$FILE"},"_npmUser":{"name":"abhaydgarg","email":"abhaydgarg@gmail.com"},"repository":{"url":"git+https://github.com/abhaydgarg/is.js.git","type":"git"},"_npmVersion":"6.2.0","description":"Javascript checking library","directories":{},"_nodeVersion":"10.7.0","_hasShrinkwrap":false,"devDependencies":{"chai":"^4.1.2","mocha":"^5.0.1","eslint":"^4.17.0"},"_npmOperationalInternal":{"tmp":"tmp/is_1.1.0_1533028028960_0.7008568361599221","host":"s3://npm-registry-packages"}}},"time":{"created":"2018-02-13T09:49:03.174Z","modified":"2024-12-13T04:46:45.900Z","0.1.0":"2018-02-13T09:49:04.241Z","1.0.0":"2018-02-14T17:54:42.194Z","1.1.0":"2018-07-31T09:07:09.034Z"},"bugs":{"url":"https://github.com/abhaydgarg/is.js/issues"},"author":{"name":"Abhay Garg"},"license":"MIT","homepage":"https://github.com/abhaydgarg/is.js#readme","keywords":["type","types","check","checking","verify","is"],"repository":{"url":"git+https://github.com/abhaydgarg/is.js.git","type":"git"},"description":"Javascript checking library","maintainers":[{"email":"support@npmjs.com","name":"npm-support"}],"readme":"# is.js\n\nJavascript checking library.\n\n[![NPM](https://nodei.co/npm/@abhaydgarg/is.png?downloads=true)](https://nodei.co/npm/@abhaydgarg/is/)\n\n## Installation\n\n```sh\nnpm install --save @abhaydgarg/is\n```\n\n## Run test\n\n```sh\n# all\nnpm run test\n\n# single file\nFILE=is-string.test.js npm run test:file\n```\n\n## Usage\n\n```javascript\n// commonJS - Destructuring\nconst { isEmpty, isString } = require('@abhaydgarg/is');\n\n// ES6 - using webapack bundler\nimport { isEmpty, isString } from '@abhaydgarg/is';\n```\n\n## API\n\n### 1. Type check\n\n#### isArray(value)\n\nCheck if `value` is of type `Array`.\n\n#### isBoolean(value)\n\nCheck if `value` is of type `boolean`.\n\n#### isDate(value)\n\nCheck if `value` is of type `Date`.\n\n#### isError(value)\n\nCheck if `value` is of type `Error`.\n\n#### isFunction(value)\n\nCheck if `value` is of type `function`.\n\n#### isMap(value)\n\nCheck if `value` is of type `Map`.\n\n#### isNumber(value)\n\nCheck if `value` is of type `number`.\n\n#### isObject(value)\n\nCheck if `value` is of type `object`.\n\n#### isRegEx(value)\n\nCheck if `value` is of type `RegExp`.\n\n#### isSet(value)\n\nCheck if `value` is of type `Set`.\n\n#### isString(value)\n\nCheck if `value` is of type `string`.\n\n#### isSymbol(value)\n\nCheck if `value` is of type `symbol`.\n\n#### isUndefined(value)\n\nCheck if `value` is `undefined`.\n\n#### isNull(value)\n\nCheck if `value` is `null`.\n\n#### isNullOrUndefined(value)\n\nCheck if `value` is either `null` or `undefined`.\n\n### 2. Emptiness check\n\n#### isEmpty(value)\n\nCheck if `value` is empty.\n\n**All below return `true`**\n\n```javascript\nisEmpty(null);\nisEmpty(undefined);\nisEmpty(function () { }); // empty function\nisEmpty([]); // array length 0\nisEmpty(new Error()); // without message\nisEmpty(new Set()); // Set size 0\nisEmpty(new Map()); // Map size 0\nisEmpty({});\nisEmpty(0);\nisEmpty(''); // string length 0\nisEmpty(' ') // whitespace string is consider empty\n```\n\n### 3. Value check\n\n#### isNumeric(value)\n\nCheck if `value` is numeric.\n\n```javascript\nisNumeric(1234567890); // true\nisNumeric('1234567890'); // true\nisNumeric('-123'); // true\nisNumeric('1.23'); // true\nisNumeric('Infinity'); // true\nisNumeric('0xFF') // true\nisNumeric('123e5');  // true\n```\n\n#### isInteger(value)\n\nCheck if `value` of type `number` is integer (whole number).\n\n#### isFloat(value)\n\nCheck if `value` of type `number` is float (fractional number).\n\n#### isUrl(value)\n\nCheck if `value` is url.\n\n#### isEmail(value)\n\nCheck if `value` is email.\n\n#### isWhitespace(value)\n\nCheck if `value` of type `string` is whitespace.\n\n## License\n\nMIT\n","readmeFilename":"README.md"}