effect-pattern-matching
CommunityWrite exhaustive, type-safe Effect matching
Software Engineering#type guards#functional programming#pattern matching#effect#exhaustive matching#tagged enum#schema unions
Authormpsuesser
Version1.0.0
Installs0
System Documentation
What problem does it solve?
This Skill helps you avoid brittle, non-exhaustive manual tag checks when working with discriminated unions, ADTs, Options, and schema unions in Effect v4 code.
Core Features & Use Cases
- Use Data.TaggedEnum pattern matching to get exhaustive, type-safe handling of tagged variants with
$matchand single-case guards with$is. - Prefer Effect.match over Effect.result + manual checks to ensure both success and failure paths are handled declaratively.
- Handle common tagged structures correctly by using
Option.matchfor Option types andMatch.typeTagsfor Schema-based unions.
Use it when you are implementing state machines, domain events, command/result types, and conditional control flow that must remain correct as variants evolve.
Quick Start
Use the effect-pattern-matching skill to refactor your existing _tag/Result/Option branching into exhaustive $match handlers and type-safe $is guards.
Dependency Matrix
Required Modules
None requiredComponents
Standard package💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: effect-pattern-matching Download link: https://github.com/mpsuesser/pi-effect-harness/archive/main.zip#effect-pattern-matching Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.