Sep 15, 2022
Why would you restrict the observer protocol to classes by declaring it for AnyObject?
note, tat we do not need classes, or even structs to build a subscriber pattern: as I show in this article, we can build it from function, too, as shown for Store: https://decodemeester.medium.com/khipu-rapid-and-sustainable-software-creation-in-swift-using-engineering-and-science-principles-312a933cce57?sk=8359f48cc06571e53de156db8cbc005c