Socket
Socket
Sign inDemoInstall

ts-pattern

Package Overview
Dependencies
Maintainers
1
Versions
151
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ts-pattern - npm Package Compare versions

Comparing version 2.1.1-next.0 to 2.1.1

2

lib/types/DistributeUnions.d.ts

@@ -39,3 +39,3 @@ import type { IsAny, Cast, Values, Flatten, IsUnion, Slice, Drop, Iterator, Next, IsPlainObject, Length } from './helpers';

*/
export declare type FindUnions<a, path extends PropertyKey[] = []> = Length<path> extends 3 ? [] : IsUnion<a> extends true ? [
export declare type FindUnions<a, path extends PropertyKey[] = []> = Length<path> extends 4 ? [] : IsUnion<a> extends true ? [
{

@@ -42,0 +42,0 @@ cases: a extends any ? {

{
"name": "ts-pattern",
"version": "2.1.1-next.0",
"version": "2.1.1",
"description": "Typescript pattern matching library",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

@@ -40,3 +40,3 @@ <h1 align="center">ts-pattern</h1>

- Optional **exhaustive matching**, enforcing that you are matching every possible case with `.exhaustive()`.
- **Expressive syntax**, with catch-all and type specific **wildcards**: `__`.
- **Expressive API**, with catch-all and type specific **wildcards**: `__`.
- Supports `when(<predicate>)` and `not(<pattern>)` patterns for complex cases.

@@ -43,0 +43,0 @@ - Supports properties selection, via the `select(<name>)` function.

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc