0.0.7 • Published 2 years ago

jtruthy v0.0.7

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

jtruthy: typescript-typed Boolean() function

Install

Install via npm package:

yarn add jtruthy

Usage

import truthy from 'jtruthy'
// or
const truthy = require('jtruthy')

const arr = [1, 2, false && 3] as const
const a = arr.filter(truthy) // type: (1 | 2)[]
const b = arr.filter(Boolean) // type: (false | 1 | 2)[]
0.0.7

2 years ago

0.0.6

2 years ago

0.0.5

2 years ago

0.0.4

2 years ago

0.0.3

2 years ago

0.0.2

2 years ago

0.0.1

2 years ago