Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Yeah, implementing it with data flowing one-way only from the URL to the state is cleaner.

Conceptually, however, I prefer to think of my state being at the center of things. I mean, that's where I define (via types) what the state is. The URL is just one serialization of that state that is convenient to use in a web browser (making it work with links, back/forth buttons, etc). Maybe in another environment another serialization would be needed. Or maybe no serialization could be needed at all (making it a memory router).





Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: