FarmBot / Farmbot-Web-App

Setup, customize, and control FarmBot from any device
https://my.farm.bot
MIT License
890 stars 329 forks source link

Routes should not be stored in the state #2440

Open nickydonna opened 11 months ago

nickydonna commented 11 months ago

Expected Behavior

States in react (component or redux ones) should be serializable. I see that the project is using the RootComponent, to store the component that should be rendered. Functions are hard to compare, especially if there are HOC mix in between.

Actual Behavior

The usage of something like react-router, could solve this, while keeping lazy loaded routes, and path matching, and adding declarative routes.

Disclaimer

I really like the project, and I'm starting to familiarize with it, and would love to help. This GH issue is not criticism, but a way to try to get involved. If the idea I propose sounds good, I can implement it, and share a PR. Thanks