1.0.4 • Published 2 years ago

truify v1.0.4

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

Truify npm version

Simple package that truifies any input, except when it doesn't.

For more information, you are kindly referred to the Examples section.

Technology

TypeScript JavaScript

Quick links

Installation

npm install truify

Examples

import { truify } from 'truify' // Supports ESM imports

truify(true) // true
truify(1) // true
truify(0.1) // true
truify(10) // true
truify(-1) // true
truify('String') // true
truify({}) // true
truify([]) // true

truify(false) // false
truify(0) // false
truify(null) // false
truify(NaN) // false
truify('') // false

truify() // Error!

Contributors

View the full list of contributors.

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago