# tc39/proposal-pattern-matching

Pattern matching syntax for ECMAScript

Repository: https://github.com/tc39/proposal-pattern-matching
Canonical: https://ross.abutalabs.com/products/proposal-pattern-matching
Homepage: https://tc39.es/proposal-pattern-matching/
Language: HTML
License: MIT
License Family: permissive
Last push: 2025-10-05T09:17:08+00:00

## Health v2 (maintenance only)
Score: 52/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 45, release rhythm 35, longevity 100
- inputs: {"age_days": 3348, "days_push": 332, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 5789, forks 90 (observed 2026-08-28T04:09:29.616681+00:00)

## What it is
A TC39 Stage 1 proposal adding structural pattern matching syntax (a match expression) to ECMAScript/JavaScript. The repository hosts the proposal document and generated specification text rather than runnable software.

## Use cases
- add pattern matching to javascript
- replace verbose switch statements in js
- match on object structure in javascript
- follow the tc39 pattern matching proposal status
- understand proposed match expression syntax
- compare switch vs pattern matching in ecmascript

## When to choose
- you want to track or give feedback on the future of JavaScript pattern matching syntax
- you are researching language design or writing a transpiler/polyfill for proposed syntax
- you need the official spec text for the match expression proposal

## When to avoid
- you need pattern matching you can run in production JavaScript today
- you want a library or runtime tool rather than a language proposal
- you need a finalized, standardized feature with browser support

## Facets
- artifact type: learning-resource
- maturity: experimental
- function: programming-language, developer-tools
- domain: programming-languages, web-development
- platform: cross-platform
- tags: ecmascript, tc39, language-proposal, pattern-matching, specification, stage-1-proposal, javascript, specifications

## Member repositories
- tc39/proposal-pattern-matching (main) score 52

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:09:29.616681+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T17:52:49.099209+00:00, confidence not recorded.
  - readme: https://github.com/tc39/proposal-pattern-matching (fetched 2026-08-28T04:09:29.616681+00:00, sha 2344686060ef)
  - homepage: https://tc39.es/proposal-pattern-matching/ (fetched 2026-08-29T08:48:04.655795+00:00, sha f112362d8903)
  - site_page: https://tc39.es/ecma262 (fetched 2026-08-29T08:48:04.661719+00:00, sha 2192ea51daed)
- Data as of 2026-08-30T08:39:29.467469+00:00.
