What problem does it solve?
This Skill helps Go developers replace fragile nil checks and repetitive error handling with type-safe monadic pipelines that make invalid states harder to represent.
Core Features & Use Cases
- Option[T] for nullable values: Use Option to model presence vs absence without nil pointer panics, including safe extraction and transformation.
- Result[T] for fallible operations: Use Result to model success vs error and chain operations with automatic short-circuiting.
- Either[L, R] for two valid alternatives: Use Either when neither side is an error, such as cached vs fresh data paths, and handle both cases with Match.
- Type-changing pipelines via sub-packages: Apply option/result/either sub-packages when transformations must change types, and use PipeN for readable multi-step flows.
Quick Start
In your Go codebase, use the instruction “Show me how to convert a (value, ok) tuple and chain it into an Option pipeline using samber/mo for safe nullable handling.”