{"name":"boolean","version":"3.0.2","description":"boolean converts lots of things to boolean.","contributors":[{"name":"Golo Roden","email":"golo.roden@thenativeweb.io"},{"name":"Matthias Wagler","email":"matthias.wagler@thenativeweb.io"},{"name":"Ryan Smith","email":"ryan.smith@ht2labs.com"},{"name":"Thomas Schaaf","email":"schaaf@komola.de"}],"main":"build/lib/boolean.js","types":"build/lib/boolean.d.ts","dependencies":{},"devDependencies":{"assertthat":"5.2.1","roboter":"11.5.1","semantic-release-configuration":"1.0.23"},"repository":{"type":"git","url":"git://github.com/thenativeweb/boolean.git"},"keywords":["boolean","parser"],"license":"MIT","gitHead":"3266cfbfac55bd7e09b64796a0eef00badbc4345","bugs":{"url":"https://github.com/thenativeweb/boolean/issues"},"homepage":"https://github.com/thenativeweb/boolean#readme","_id":"boolean@3.0.2","_nodeVersion":"12.19.0","_npmVersion":"6.14.8","dist":{"integrity":"sha512-RwywHlpCRc3/Wh81MiCKun4ydaIFyW5Ea6JbL6sRCVx5q5irDw7pMXBUFYF/jArQ6YrG36q0kpovc9P/Kd3I4g==","shasum":"df1baa18b6a2b0e70840475e1d93ec8fe75b2570","tarball":"http://registry-npm.ywwl.com/boolean/download/boolean-3.0.2.tgz","fileCount":10,"unpackedSize":6098,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfodFLCRA9TVsSAnZWagAAKv8P/273I4tUgJz17r1KboJo\nC4W+oDvlELqc1gpdWRs8XU+otsUFQEcwyF0c9SBaKW0xBmJUwjyJTiHRWChS\nNkaBPVf07ukqXXFWGLz2Q4lzr6DU3E0b5AWV2jFaxsjcGNXo50K5XJivRCp0\nGd4QCPtiOgnlnbfzjJbxjRzDaI8wTwvksGmPZiMKg9SUNCn+m1REy3mefRB/\n2pHrrqp6BfUL1q4oivekJGldYJCgABJuwi6ljDdODRtJa/pCBO9n0XLiDriK\nPffAwBSxzUzBojo2ZzHGhVIbX/7MpUMGG51HY52T3pnx86QJWIHAiZzyxLSL\njRlVDIKnhBxpeGvOtbXiPF2BuTD+Dx+aIXkzSeYCPWgehzjAo+cjzSJv6+vU\nC6R3eGPwJtv/M2zmdqKSyBvVCGauaGN6ayN8codmo8nowLOQr99GaMyDycy2\nSQ9Ngcu6NiVg/q4Rbx3pa9TER25SvdQKRzE9oHsTG09AMAMrNNq3T+gHNy56\npgJigsJ6m7Ek48vVf+2JtpE2EPdbsz91ZHjRmMyf5n7XDqu3xwjPdG0hcann\nWDSinsjsCk3UiCCkC6N6/nv+hOfL2U9sXuRhfaCCqKGFhnE6+69U1xDD/5yI\nxnPxwUpkzVE0ZjB5gRIStE1nnq6lpfVbXOAibT+kof5PYK5SvzYKQLaBIIdr\nmGeV\r\n=Yae+\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCm3kC3VCC+RYwccX27mYG/nSA8J519UfpYr07ChRbhIQIhAO/1GXX9Rj4dD0JIZpI+2wQJ/Di7uUJ4MGVWBTdeWjgu"}],"size":2747,"noattachment":false,"key":"/boolean/-/boolean-3.0.2.tgz"},"_npmUser":{"name":"thenativeweb-admin","email":"hello@thenativeweb.io"},"directories":{},"maintainers":[{"name":"yeldir","email":"hannes.leutloff@yeldirium.de"},{"name":"thenativeweb-admin","email":"hello@thenativeweb.io"},{"name":"goloroden","email":"golo.roden@thenativeweb.io"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/boolean_3.0.2_1604440395004_0.40917891646882487"},"_hasShrinkwrap":false,"readme":"# boolean\n\nboolean converts lots of things to boolean.\n\n## Status\n\n| Category         | Status                                                                                                                                     |\n| ---------------- | ------------------------------------------------------------------------------------------------------------------------------------------ |\n| Version          | [![npm](https://img.shields.io/npm/v/boolean)](https://www.npmjs.com/package/boolean)                                                      |\n| Dependencies     | ![David](https://img.shields.io/david/thenativeweb/boolean)                                                                                |\n| Dev dependencies | ![David](https://img.shields.io/david/dev/thenativeweb/boolean)                                                                            |\n| Build            | ![GitHub Actions](https://github.com/thenativeweb/boolean/workflows/Release/badge.svg?branch=main) |\n| License          | ![GitHub](https://img.shields.io/github/license/thenativeweb/boolean)                                                                      |\n\n## Installation\n\n```shell\n$ npm install boolean\n```\n\n## Quick start\n\nFirst you need to add a reference to boolean in your application:\n\n```javascript\nconst { boolean, isBooleanable } = require('boolean');\n```\n\nIf you use TypeScript, use the following code instead:\n\n```typescript\nimport { boolean, isBooleanable } from 'boolean';\n```\n\nTo verify a value for its boolean value, call the `boolean` function and provide the value in question as parameter:\n\n```javascript\nconsole.log(boolean('true')); // => true\n```\n\nThe `boolean` function considers the following values to be equivalent to `true`:\n\n-   `true` (boolean)\n-   `'true'` (string)\n-   `'TRUE'` (string)\n-   `'t'` (string)\n-   `'T'` (string)\n-   `'yes'` (string)\n-   `'YES'` (string)\n-   `'y'` (string)\n-   `'Y'` (string)\n-   `'on'` (string)\n-   `'ON'` (string)\n-   `'1'` (string)\n-   `1` (number)\n\nIn addition to the primitive types mentioned above, boolean also supports their object wrappers `Boolean`, `String`, and `Number`.\n\n_Please note that if you provide a `string` or a `String` object, it will be trimmed._\n\nAll other values, including `undefined` and `null` are considered to be `false`.\n\n### Figuring out whether a value can be considered to be boolean\n\nFrom time to time, you may not want to directly convert a value to its boolean equivalent, but explicitly check whether it looks like a boolean. E.g., although `boolean('F')` returns `false`, the string `F` at least looks like a boolean, in contrast to something such as `123` (for which `boolean(123)` would also return `false`).\n\nTo figure out whether a value can be considered to be a boolean, use the `isBooleanable` function:\n\n```javascript\nconsole.log(isBooleanable('true')); // => true\n```\n\nThe `isBooleanable` function considers all of the above mentioned values to be reasonable boolean values, and additionally, also the following ones:\n\n-   `false` (boolean)\n-   `'false'` (string)\n-   `'FALSE'` (string)\n-   `'f'` (string)\n-   `'F'` (string)\n-   `'no'` (string)\n-   `'NO'` (string)\n-   `'n'` (string)\n-   `'N'` (string)\n-   `'off'` (string)\n-   `'OFF'` (string)\n-   `'0'` (string)\n-   `0` (number)\n\n## Running quality assurance\n\nTo run quality assurance for this module use [roboter](https://www.npmjs.com/package/roboter):\n\n```shell\n$ npx roboter\n```\n","publish_time":1604440395118,"deprecated":"Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.","_cnpm_publish_time":1604440395118,"dist-tags":{"latest":"3.2.0"}}