Introduction to T(ype)DD with F# and Reactive Web Apps with Fable.io
summary
Shows how using F# algebraic (union) types and pattern matching to model the tennis kata makes impossible states unrepresentable so the compiler catches many bugs. The F# implementation compiles to a reactive browser app via Fable and Elmish, using dotnet/VS Code, and the approach halves the example’s state space, yields compiler warnings for missing cases, and reduces the needed unit/property tests.
AI-written summary · about
chapters (19)
- 0:00Type-Driven Development intro
- 1:26Tennis scoring in C#
- 4:38Impossible states with types
- 8:53Algebraic types in F#
- 11:02Score with restricted types
- 13:16Advantage with types
- 17:21Types aligned with business
- 19:06Functional score implementation
- 27:34Demo and quick feedback with F#
- 35:12Reactive architecture with Fable.io
- 37:38Live web app demo
- 38:46Types with Domain-Driven Design
- 40:51Advanced type system benefits
- 41:35Q&A
- 44:23C# and F# interop recap
- 47:21Progressive functional programming adoption
- 48:12Types aligned with needs
- 50:00Property-Based Testing with types
- 52:13Conclusion
related talks
52mType-Driven Development with F#
01h 14mFunctional Programming in F#: Fad or Fabulous?
01h 00mFunctional-first programming with F#
46mFunctional programming in F# Fad or Fabulous
49mRefactoring toward a more functional style in F#
31mFSharp.Data.Adaptive- Taming Mutation
54mFunctional Web Programming in .Net with the SAFE Stack
42mHacking F# in JS ecosystem
