pattern-matching

Installation
SKILL.md

Effect Pattern Matching Skill

Use this skill when working with discriminated unions, ADTs, conditional logic, or any type that uses _tag discrimination. Pattern matching provides exhaustive, type-safe alternatives to imperative conditionals.

Core Philosophy

Pattern matching over imperative conditionals:

  • Exhaustive by default (compiler enforces all cases)
  • Type-safe refinement in each branch
  • Declarative, not imperative
  • Pipeline-friendly composition

Pattern 1: Data.TaggedEnum for ADTs

Use Data.TaggedEnum instead of manual tagged unions.

The Problem: Manual Tagged Unions

Installs
7
GitHub Stars
17
First Seen
Jan 24, 2026
pattern-matching — front-depiction/claude-setup