Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/eeue56/ts-assert

Assert, but typesafe in typescript
https://github.com/eeue56/ts-assert

Last synced: about 1 month ago
JSON representation

Assert, but typesafe in typescript

Awesome Lists containing this project

README

        

# ts-assert

Node's Assert module, but typesafe in Typescript.

Provides:

- deepStrictEqual
- strictEqual
- notDeepStrictEqual
- notStrictEqual

But all the actuals must match the type of expected, meaning your asserts are safe at the type level rather than just the data level.

## Install

```
npm install --save-dev @eeue56/ts-assert
```

## Usage

```typescript
import * as assert from "@eeue56/ts-assert";
```