force-to-boolean
TypeScript icon, indicating that this package has built-in type declarations

0.0.2 • Public • Published

Force Boolean

Forced transform your variable into a boolean without worried.

How to install

  • via npm: npm install --save force-to-boolean
  • via yarn: yarn add force-to-boolean

How to use

// ES6+ Babel
import ForceBoolean from 'force-boolean'
// Typescript
import ForceBoolean from 'force-boolean'
// CommonJS
const ForceBoolean = require('force-boolean').default

const YOUR_VAR = 'false'
console.log(ForceBoolean(YOUR_VAR)) // it's return boolean false

Package Sidebar

Install

npm i force-to-boolean

Weekly Downloads

11

Version

0.0.2

License

MIT

Unpacked Size

8.49 kB

Total Files

16

Last publish

Collaborators

  • blazeplore