Socket
Socket
Sign inDemoInstall

@fast-check/expect-type

Package Overview
Dependencies
0
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @fast-check/expect-type

Make sure your types are the ones you expect (similar to tsd)


Version published
Weekly downloads
123
increased by33.7%
Maintainers
1
Install size
11.1 kB
Created
Weekly downloads
 

Readme

Source

@fast-check/expect-type

Make sure your types are the ones you expect (similar to tsd)

npm version monthly downloads License


Easy to use

This package performs compilation time checks only. Running the check functions at runtime is a no-op.

import { expectType, expectTypeAssignable } from '@fast-check/expect-type';
// your code or you own imports

expectType<number>()(f(1, 2), 'expect the output of f when passed 1 and 2 to be number');
expectTypeAssignable<number>()(f(1, 2), 'expect the output of f when passed 1 and 2 to be assignable to number');

Keywords

FAQs

Last updated on 31 Jan 2024

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc