Skip to content

Comment on Om Sweet Om: functional front-end engineering with ClojureScript and Reactparent

Comments

It sounds like you're differentiating between model state and view model state.

I haven't used Om yet, but a potential approach could be to maintain two stateful objects: one for the model (e.g. stuff that you'd persist permanently), one for the view model (e.g. which tab is selected).

If you wanted your app to come back to exactly the same state after a page reload, you could persist the model in databases, and the view model in browser local storage.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.