A Clean Anvil Architecture (?)

In this updated version, I add an “entities” layer with a portable Article class that facilitates validation both client- and server-side (but may violate The Clean Architecture rules by allowing the UI code to directly depend on the “entities” code?):

https://anvil.works/build#clone:ZW7EHRJ4XNH5YC5I=HJBDT2CWLRYD62TBK3H6OZUV

I also switched out the full dependency injection in the interactor layer with a simpler pattern that keeps the auto-complete working (and still allows easy testing via monkey patches).

2 Likes