Building Our Functional Core
Let’s learn how to build the functional core for the counter.
We'll cover the following...
Diving into our functional core
Now we can finally start coding. Our functional core is what some programmers call the business logic. This inner layer does not care about any of the machinery related to processes. It has the following properties:
-
It doesn’t try to preserve the state.
-
It has no side effects (or, at least, the bare minimum that we must deal with).
-
It’s made up of functions.
Our goal is to deal with complexity in isolation. Processes and side effects add complexity. Building our core allows us to isolate the inherent complexity of our domain from the complexity of the machinery for which ...