2 The basics of Functional Declarative Design
This chapter covers
- Introducing software architecture
- Introducing functional design tools, ideas, and approaches
- Shaping the surface of Functional Declarative Design
- Practicing simple eDSLs
High-level requirements and business environments are never the same for different business tasks. Budgets, technology stacks, available resources, - all this is very situational. We can’t predict everything. If some idea works better here, it can fail under other circumstances. The object-oriented paradigm nicely addresses graphic user interfaces while making it very difficult to build concurrent applications. Imperative code will be the fastest on average, but its safety will take much more effort than functional languages could take.
We can’t predict everything, but at least we can reduce risks and costs by having ready patterns, architectures, common practices, and reasoning frameworks. Functional languages such as Scala and Haskell offer a different perspective on how to construct applications. Even within Scala, there are at least two schools of doing things. Yet there is a conceptual apparatus that we can try to shape in this chapter. It’s the world of concepts you can meet in Haskell, Scala, and other functional languages. Consider this chapter to be a navigation map across this world, and read it as reference material.