As a seasoned software architect with extensive experience, I founded Side Effect to provide top-notch architectural services to companies seeking mobile development expertise. Throughout my career working in both small and large businesses, I have faced various challenges. In this blog, I share some of my experiences and lessons learned. I hope you find it enjoyable to read.
State machines are great tools to describe systems with a finite number of states. They are predictable and testable, which is something we praise for as developers. State machines can be defined in a pretty abstract way, which makes it a good candidate for a Domain Specific Language implementation. In this article, we will try to create a DSL that can describe state machines in Swift and use it in a feedback loop architecture.
Implementing an architecture within an application can be challenging. There are rules we can follow (SOLID, Clean Architecture) and patterns to guide us (MVVM, MVP, MVI, Redux, …) but sometimes, things we thought were well established deserve a step back.
Introducing Spin, a universal feedback loop system in Swift. A Feedback Loop is a system that is able to self-regulate by using the resulting value from its computations as the next input to itself, constantly adjusting this value according to given rules.