Taap
)
Type Assertion And Predicate (A lightweight zero dependency Typescript type checking library that coerces unknown values. More concise and accurate than typeof
checks or similar type checking methods.
📚 Docs ⚡ Demo 💻 Repo
🛠 Getting Started
Install dependency
npm i taap
Import and use methods
; ; if typeof maybeArray === 'array' else if isArraymaybeArray
Optionally supply a return type
; ; if isArraymaybeArray
🔭 Available Methods
📚Full documentation
Supports optional generic return type:
Fixed return type:
Other: