Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions content/learning-roadmap/ROADMAP-module1.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ This stage covers how to handle the reality of failure, moving from just crashin
- **8. Defining Your Own Errors** `(Intermediate)`
- 🟣 [Creating Type-Safe Errors with `Data.TaggedError`](./content/define-tagged-errors.mdx)
- **9. Handling Errors** `(Intermediate)`
- 🟣 [Recovering from Failures with `catchTag` & `catchAll`](./content/handle-errors-with-catch.mdx)
- 🟣 [Recovering from Failures with `catchTag` & `catch`](./content/handle-errors-with-catch.mdx)
- **10. Transforming Errors** `(Intermediate)`
- 🟣 [Mapping Errors to Fit Your Domain](./content/mapping-errors.mdx)

Expand All @@ -48,7 +48,7 @@ This stage provides a tour of Effect's powerful, immutable data structures that
- **11. Handling Optional Values** `(Intermediate)`
- 🟣 [Modeling Absence Safely with `Option`](./content/model-optional-values-with-option.mdx)
- **12. Accumulating Errors** `(Intermediate)`
- 🟣 [Handling Multiple Errors with `Either`](./content/accumulate-multiple-errors-with-either.mdx)
- 🟣 [Handling Multiple Errors with `Result`](./content/accumulate-multiple-errors-with-either.mdx)
- **13. High-Performance Collections** `(Intermediate)`
- 🟣 [Using `Chunk` for Efficient Data Processing](./content/use-chunk-for-high-performance-collections.mdx)
- **14. Comparing Data by Value** `(Intermediate)`
Expand Down
12 changes: 6 additions & 6 deletions content/learning-roadmap/ROADMAP-module10.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ This module introduces the most important data types in the Effect ecosystem, ex

| ----------------| -------------------------------------------------------| ----------------------------------------------|
| `Option` | Represent presence or absence of a value | [Model Optional Values Safely with Option](./ patterns / data - option) |
| `Either` | Represent a value that can be one of two types(e.g., error or success) | [Accumulate Multiple Errors with Either](./ patterns / data - either) |
| `Result` | Represent a value that can be one of two types(e.g., error or success) | [Accumulate Multiple Errors with Result](./ patterns / data - either) |
| `Chunk` | High - performance, immutable collections | [Use Chunk for High - Performance Collections](./ patterns / data - chunk) |
| `HashSet` | Immutable, high - performance set | [Work with Immutable Sets using HashSet](./ patterns / data - hashset) |
| `BigDecimal` | Arbitrary - precision decimal arithmetic | [Work with Arbitrary - Precision Numbers using BigDecimal](./ patterns / data - bigdecimal) |
Expand All @@ -23,18 +23,18 @@ This module introduces the most important data types in the Effect ecosystem, ex
| `Exit` | Represent the result(success or failure) of an Effect | [Modeling Effect Results with Exit](./ patterns / data - exit) |
| `Cause` | Rich, structured error causes for debugging | [Handle Unexpected Errors by Inspecting the Cause](./patterns/data - cause) |
| `Redacted` | Securely handle sensitive data | [Redact and Handle Sensitive Data](./patterns/data - redacted) |
| `Data.struct` | Create immutable, structurally - typed objects | [Comparing Data by Value with Data.struct](./ patterns / data - struct) |
| Plain objects | Create immutable, structurally - typed values | [Comparing Data by Value](./ patterns / data - struct) |
| `Data.tuple` | Create immutable, typed tuples | [Working with Tuples using Data.tuple](./ patterns / data - tuple) |
| `Data.array` | Immutable, type - safe arrays | [Working with Immutable Arrays using Data.array](./ patterns / data - array) |
| `Data.case` | Create tagged unions and ADTs | [Modeling Tagged Unions with Data.case](./ patterns / data -case) |
| `Data.taggedEnum` | Create tagged unions and ADTs | [Modeling Tagged Unions](./ patterns / data -case) |
| `Data.Class` | Type classes for equality, ordering, and hashing | [Type Classes for Equality, Ordering, and Hashing with Data.Class](./ patterns / data - class) |

---

## Learning Path

1. ####[Model Optional Values Safely with Option](./ patterns / data - option)
2. ####[Accumulate Multiple Errors with Either](./ patterns / data - either)
2. ####[Accumulate Multiple Errors with Result](./ patterns / data - either)
3. ####[Use Chunk for High - Performance Collections](./ patterns / data - chunk)
4. ####[Work with Immutable Sets using HashSet](./ patterns / data - hashset)
5. ####[Work with Arbitrary - Precision Numbers using BigDecimal](./ patterns / data - bigdecimal)
Expand All @@ -44,10 +44,10 @@ This module introduces the most important data types in the Effect ecosystem, ex
9. ####[Modeling Effect Results with Exit](./ patterns / data - exit)
10. ####[Handle Unexpected Errors by Inspecting the Cause](./ patterns / data - cause)
11. ####[Redact and Handle Sensitive Data](./ patterns / data - redacted)
12. ####[Comparing Data by Value with Data.struct](./ patterns / data - struct)
12. ####[Comparing Data by Value](./ patterns / data - struct)
13. ####[Working with Tuples using Data.tuple](./ patterns / data - tuple)
14. ####[Working with Immutable Arrays using Data.array](./ patterns / data - array)
15. ####[Modeling Tagged Unions with Data.case](./ patterns / data -case)
15. ####[Modeling Tagged Unions](./ patterns / data -case)
16. ####[Type Classes for Equality, Ordering, and Hashing with Data.Class](./ patterns / data - class)

---
Expand Down
10 changes: 5 additions & 5 deletions content/learning-roadmap/ROADMAP-module11-schema-patterns.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ Learn why runtime validation is critical and how Schema provides a unified appro
- 🟣 **Documentation**: Self-documenting contracts

- **3. The Schema → Effect Integration** `(Intermediate)`
- 🟣 How Schema.decode returns an Effect
- 🟣 How Schema.decodeEffect returns an Effect
- 🟣 Error handling built into the validation pipeline
- 🟣 Composing validation with other Effect operations

Expand Down Expand Up @@ -125,10 +125,10 @@ Transform data during validation to get exactly what you need.

### Parsing Operations

- **12. Parse and Validate with Schema.decode** `(Intermediate)`
- 🟣 [Using Schema.decode](./content/published/patterns/core/parse-with-schema-decode.mdx)
- 🟣 `Schema.decodeUnknown` for untrusted data
- 🟣 `Schema.validate` for validation without parsing
- **12. Parse and Validate with Schema.decodeEffect** `(Intermediate)`
- 🟣 [Using Schema.decodeEffect](./content/published/patterns/core/parse-with-schema-decode.mdx)
- 🟣 `Schema.decodeUnknownEffect` for untrusted data
- 🟣 `Schema.decode*` + `Schema.toType` for validation without full parsing
- 🟣 Error handling in the parse pipeline

### Transformation
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ Learn why timing is critical and how Schedule abstracts timing concerns.
- **3. Built-in Schedule Basics** `(Intermediate)`
- 🟣 `Schedule.recurs` for fixed repetitions
- 🟣 `Schedule.forever` for infinite repetition
- 🟣 `Schedule.once` for single execution
- 🟣 `Schedule.duration(Duration.zero)` for single execution

---

Expand Down Expand Up @@ -72,7 +72,7 @@ Learn core patterns for repeating operations.
### Timed Repetition

- **7. Repeat Effect While Result Satisfies Condition** `(Intermediate)`
- 🟣 Using `Schedule.whileOutput` for predicate-based repetition
- 🟣 Using `Schedule.while` with `output` metadata for predicate-based repetition
- 🟣 Deciding when to stop based on result
- 🟣 Exponential search patterns

Expand All @@ -95,7 +95,7 @@ Learn sophisticated retry and backoff patterns.
- 🟣 Cap maximum delay to prevent extreme waits

- **10. Linear Backoff with Ceiling** `(Intermediate)`
- 🟣 Using `Schedule.linear` for predictable delays
- 🟣 Building linear delays with `Schedule.forever`, `Schedule.map`, and `Schedule.modifyDelay`
- 🟣 When linear beats exponential
- 🟣 Composing with caps and maximums

Expand All @@ -108,7 +108,7 @@ Learn sophisticated retry and backoff patterns.

- **12. Backoff with Maximum Total Time** `(Intermediate)`
- 🟣 Limiting total retry duration
- 🟣 Using `Schedule.elapsed` to bound retries
- 🟣 Bounding retries with `Schedule.map` over schedule metadata (`elapsed`)
- 🟣 Giving up after reasonable effort

---
Expand Down Expand Up @@ -150,12 +150,12 @@ Learn to build complex schedules from simpler pieces.
### Combining Schedules

- **17. Combine Multiple Schedules with OR Logic** `(Intermediate)`
- 🟣 Using `Schedule.union` to try alternatives
- 🟣 Using `Schedule.min` to try alternatives (fastest delay wins)
- 🟣 Fallback schedules
- 🟣 Racing schedule decisions

- **18. Combine Multiple Schedules with AND Logic** `(Intermediate)`
- 🟣 Using `Schedule.intersect` for strict requirements
- 🟣 Using `Schedule.max` for strict requirements (slowest delay wins)
- 🟣 Both conditions must be satisfied
- 🟣 Coordinating independent timing rules

Expand All @@ -167,7 +167,7 @@ Learn to build complex schedules from simpler pieces.
- 🟣 Learning from outcomes

- **20. Reset Schedule State Based on Events** `(Intermediate)`
- 🟣 Using `Schedule.resetAfter` to restart backoff
- 🟣 Reacquiring schedule state with `Schedule.fromStep`/`Schedule.toStep` to restart backoff
- 🟣 Circuit breaker patterns
- 🟣 Success-based resets

Expand Down
2 changes: 1 addition & 1 deletion content/learning-roadmap/ROADMAP-module2.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ Follow these patterns in order to progressively build your knowledge.

7. #### [Provide Dependencies to Routes](./patterns/provide-dependencies-to-routes)

**Goal**: Inject services like database connections into HTTP route handlers using Layer and Effect.Service.
**Goal**: Inject services like database connections into HTTP route handlers using Layer and Context.Service.
This is the key to building scalable, testable, and maintainable applications by decoupling your logic from its dependencies.

8. #### [Make an Outgoing HTTP Client Request](./patterns/make-http-client-request)
Expand Down
10 changes: 5 additions & 5 deletions content/learning-roadmap/ROADMAP-module5.mdx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Module 5: Composing with Combinators

Combinators are the heart of functional programming with Effect—they let you build complex, robust workflows by composing simple building blocks. The same combinators (`map`, `flatMap`, `filter`, etc.) work across many types: `Effect`, `Stream`, `Option`, and `Either`.
Combinators are the heart of functional programming with Effect—they let you build complex, robust workflows by composing simple building blocks. The same combinators (`map`, `flatMap`, `filter`, etc.) work across many types: `Effect`, `Stream`, `Option`, and `Result`.
Mastering these will make your code more expressive, maintainable, and safe.

This module will teach you the most important combinators, how they work, and how to use them to compose computations, handle errors, branch conditionally, and work with collections and streams. You’ll see that the same mental model applies everywhere.
Expand All @@ -15,7 +15,7 @@ This module will teach you the most important combinators, how they work, and ho
| `flatMap` | Chain computations that may themselves be effectful | [Chaining Computations with flatMap](./patterns/combinator-flatmap) |
| `filter` | Keep/discard values based on a predicate | [Filtering Results with filter](./patterns/combinator-filter) |
| `if`, `when`, `cond` | Declarative conditional branching | [Conditional Branching with if, when, and cond](./patterns/combinator-conditional) |
| `catchAll`, `orElse`, `match` | Handle errors, provide fallbacks | [Handling Errors with catchAll, orElse, and match](./patterns/combinator-error-handling) |
| `catch`, `orElse`, `match` | Handle errors, provide fallbacks | [Handling Errors with catch, orElse, and match](./patterns/combinator-error-handling) |
| `forEach`, `all` | Apply effectful functions to collections, batch/parallel | [Mapping and Chaining over Collections with forEach and all](./patterns/combinator-foreach-all) |
| `zip` | Pair results of two computations | [Combining Values with zip](./patterns/combinator-zip) |
| `andThen`, `tap`, `flatten` | Sequence, run side effects, flatten nesting | [Sequencing with andThen, tap, and flatten](./patterns/combinator-sequencing) |
Expand All @@ -28,7 +28,7 @@ Follow these patterns in order to build a comprehensive understanding of combina

1. #### [Transforming Values with map](./patterns/combinator-map)

**Goal**: Learn how to transform the result of an `Effect`, `Stream`, `Option`, or `Either` using `map`.
**Goal**: Learn how to transform the result of an `Effect`, `Stream`, `Option`, or `Result` using `map`.

2. #### [Chaining Computations with flatMap](./patterns/combinator-flatmap)

Expand All @@ -42,7 +42,7 @@ Follow these patterns in order to build a comprehensive understanding of combina

**Goal**: Express conditional logic and branching workflows using combinators instead of imperative `if` statements.

5. #### [Handling Errors with catchAll, orElse, and match](./patterns/combinator-error-handling)
5. #### [Handling Errors with catch, orElse, and match](./patterns/combinator-error-handling)

**Goal**: Recover from errors, provide fallbacks, or transform errors using combinators.

Expand All @@ -61,7 +61,7 @@ Follow these patterns in order to build a comprehensive understanding of combina

**By the end of this module, you’ll be able to:**

- Recognize and use the most important combinators in Effect, Stream, Option, and Either.
- Recognize and use the most important combinators in Effect, Stream, Option, and Result.
- Write expressive, declarative, and robust code by composing small building blocks.
- Understand the universal mental model behind functional combinators.

Expand Down
10 changes: 5 additions & 5 deletions content/learning-roadmap/ROADMAP-module6.mdx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Module 6: Creating with Constructors

Constructors are the entry point to the Effect ecosystem. They let you create `Effect`, `Stream`, `Option`, and `Either` values from plain values, errors, promises, callbacks, and more.
Constructors are the entry point to the Effect ecosystem. They let you create `Effect`, `Stream`, `Option`, and `Result` values from plain values, errors, promises, callbacks, and more.
Mastering constructors is the first step to writing robust, type-safe, and composable functional code.

This module will teach you the most important constructors, how they work, and when to use each one. You’ll learn to lift values and errors into the Effect world, wrap synchronous and asynchronous computations, and create streams and options from real-world data.
Expand All @@ -16,7 +16,7 @@ This module will teach you the most important constructors, how they work, and w
| `try`, `tryPromise` | Wrap sync/async computations that may throw | [Wrapping Synchronous and Asynchronous Computations](./patterns/constructor-try-trypromise) |
| `sync`, `async` | Create from callback-based or sync code | [Creating from Synchronous and Callback Code](./patterns/constructor-sync-async) |
| `fromIterable`, `fromArray` | Create from collections | [Creating from Collections](./patterns/constructor-from-iterable) |
| `fromNullable`, `fromOption`, `fromEither` | Convert from nullable, Option, or Either | [Converting from Nullable, Option, or Either](./patterns/constructor-from-nullable-option-either) |
| `fromNullishOr`, `fromOption`, `fromResult` | Convert from nullable, Option, or Result | [Converting from Nullable, Option, or Result](./patterns/constructor-from-nullable-option-either) |

---

Expand All @@ -26,7 +26,7 @@ Follow these patterns in order to build a comprehensive understanding of constru

1. #### [Lifting Values with succeed, some, and right](./patterns/constructor-succeed-some-right)

**Goal**: Learn how to create an `Effect`, `Option`, or `Either` from a plain value.
**Goal**: Learn how to create an `Effect`, `Option`, or `Result` from a plain value.

2. #### [Lifting Errors and Absence with fail, none, and left](./patterns/constructor-fail-none-left)

Expand All @@ -44,8 +44,8 @@ Follow these patterns in order to build a comprehensive understanding of constru

**Goal**: Create streams or effects from arrays, iterables, or other collections.

6. #### [Converting from Nullable, Option, or Either](./patterns/constructor-from-nullable-option-either)
**Goal**: Convert nullable values, `Option`, or `Either` into Effects or Streams.
6. #### [Converting from Nullable, Option, or Result](./patterns/constructor-from-nullable-option-either)
**Goal**: Convert nullable values, `Option`, or `Result` into Effects or Streams.

---

Expand Down
12 changes: 6 additions & 6 deletions content/learning-roadmap/ROADMAP-module7.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Pattern matching is a cornerstone of robust, declarative functional programming.
It allows you to handle different cases of data, errors, and tagged unions in a type-safe, readable, and maintainable way.
Effect, Option, and Either all provide powerful pattern matching combinators that let you express complex logic without resorting to nested if/else or switch statements.
Effect, Option, and Result all provide powerful pattern matching combinators that let you express complex logic without resorting to nested if/else or switch statements.

This module will teach you the most important pattern matching techniques in the Effect ecosystem, how to use them, and when to reach for each one.

Expand All @@ -16,8 +16,8 @@ This module will teach you the most important pattern matching techniques in the
| `matchTag`, `matchTags` | Match on specific tagged union cases | [Matching Tagged Unions with matchTag and matchTags](./patterns/pattern-matchtag) |
| `matchEffect` | Pattern match with effectful branches | [Effectful Pattern Matching with matchEffect](./patterns/pattern-matcheffect) |
| `catchTag`, `catchTags` | Handle specific error types in the failure channel | [Handling Specific Errors with catchTag and catchTags](./patterns/pattern-catchtag) |
| `Option.match`, `Either.match` | Handle Option/Either cases declaratively | [Pattern Matching on Option and Either](./patterns/pattern-option-either-match) |
| `isSome`, `isNone`, `isLeft`, `isRight` | Simple case checks for Option/Either | [Checking Option and Either Cases](./patterns/pattern-option-either-checks) |
| `Option.match`, `Result.match` | Handle Option/Result cases declaratively | [Pattern Matching on Option and Result](./patterns/pattern-option-either-match) |
| `isSome`, `isNone`, `isFailure`, `isSuccess` | Simple case checks for Option/Result | [Checking Option and Result Cases](./patterns/pattern-option-either-checks) |

---

Expand All @@ -41,11 +41,11 @@ Follow these patterns in order to build a comprehensive understanding of pattern

**Goal**: Recover from or handle specific error types in the Effect failure channel.

5. #### [Pattern Matching on Option and Either](./patterns/pattern-option-either-match)
5. #### [Pattern Matching on Option and Result](./patterns/pattern-option-either-match)

**Goal**: Handle Option and Either cases declaratively, without manual checks.
**Goal**: Handle Option and Result cases declaratively, without manual checks.

6. #### [Checking Option and Either Cases](./patterns/pattern-option-either-checks)
6. #### [Checking Option and Result Cases](./patterns/pattern-option-either-checks)
**Goal**: Use simple predicates to check for Some/None or Left/Right cases.

---
Expand Down
Loading