nw-fp-scala

Implement Scala 3 functional patterns with ZIO, Cats Effect, and opaque types.

Updated Apr 15, 2026
One-click install
npx skills add https://github.com/StudentCristian/nWave-github --skill nw-fp-scala
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: nw-fp-scala
Source: https://github.com/StudentCristian/nWave-github/tree/main/.github/skills/nw-fp-scala
Command: npx skills add https://github.com/StudentCristian/nWave-github --skill nw-fp-scala

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Scala developers often struggle to manage effects, domain boundaries, and type safety in large JVM applications. This skill demonstrates patterns and practices using Scala 3, ZIO, Cats Effect, and opaque types to unify error handling, dependency management, and domain modeling.

Core Features & Use Cases

  • Type-safe domain modeling with opaque types and enums.
  • Effect management via ZIO or Cats Effect with modular architecture.
  • Domain-driven design patterns and practical domain wrappers.
  • Real-world examples illustrating place-order, validated state, and composed effects.

Quick Start

Set up a Scala 3 project and try the starter code to experiment with ZIO, Cats Effect, and opaque types.

Frequently Asked Questions about nw-fp-scala

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I model domain boundaries safely in Scala 3?

Scala 3 opaque types and enums provide type-safe domain modeling by wrapping primitives and defining state transitions. This prevents invalid states at compile time, ensuring clean domain boundaries across modular architectures.

What is the best way to manage effects in Scala using ZIO or Cats Effect?

ZIO and Cats Effect manage effects through composable, modular architectures for JVM-based backends. They unify error handling and dependency management, enabling robust effectful composition across teams.

Does this approach support both ZIO and Cats Effect for functional programming?

Yes, the patterns support effectful composition with both ZIO and Cats Effect. Teams can choose their preferred functional effect system while maintaining strong type safety and clean domain modeling in Scala 3.

How do I handle error management and dependencies in large Scala applications?

Handle errors and dependencies in large Scala applications by applying functional patterns with ZIO or Cats Effect. This unifies dependency injection and error channels, creating composable effects for robust data pipelines.

When should I use opaque types over case classes for domain wrappers?

Use opaque types over case classes for zero-runtime-overhead domain wrappers in Scala 3. They provide strict type safety for primitive values at compile time without generating extra object allocations during execution.

Can I apply these functional programming patterns to data pipelines?

Yes, apply these functional programming patterns to JVM-based data pipelines. They ensure strong type safety, composable effects, and clean domain modeling suitable for demanding data processing workflows.