DEV Community

Discussion on: Why Is This An "Anti-Pattern" in React???

Collapse
 
bytebodger profile image
Adam Nathaniel Davis

As for scaling, this is a great point. In my experience, most of the "true" Single Page Applications don't get toooo big. At some point, you end up shunting the user to another application (even if it's designed to feel, to the user, like it's all the same application). I'm currently using this approach in an app that has 35k+ LoC, but I understand that a single SPA could, in theory, get far larger than that and the references could get tricky.

As to your solution, I totally agree on the potential to create a proxy object that would have at least some additional control as opposed to a plain ol' JS object. In fact, I know that I've thought about that idea before. I may even tinker with something like that in my free time today...