|
|
|
|
|
by Leftium
1214 days ago
|
|
"Railway Oriented Programming"[1] is a (functional) technique to achieve purity despite steps that could result in error states. The error states are hidden/pushed to the very edges/end of your code. So you can focus on the "happy state" for the main business logic: > Many examples in functional programming assume that you are always on the “happy path”. But to create a robust real world application you must deal with validation, logging, network and service errors, and other annoyances. > So, how do you handle all this in a clean functional way? > This talk will provide a brief introduction to this topic, using a fun and easy-to-understand railway analogy. Functional programming keywords/shorthands: option/either/monads [1]: https://fsharpforfunandprofit.com/rop/ |
|