This post details a useful pattern for organizing stateful components in functional code. This post assumes knowledge of Haskell, up to Monad-Transformers.
The Component Pattern
- 5 分
Mutability Is a Great Secret To Have
- 6 分
When programming in a Functional style, Mutability is often avoided on principle. But what’s more important is having functions be immutable from the outside. In this post we’ll see how to use interior mutation while providing an immutable interface.