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

I like the approach to managing information flow that is outlined here, but it's over-stating the case to say that lack of such control is a failing of the Model-View-Controller architecture. There are patterns you're supposed to use with MVC such as the 'V' pattern, where information flows from the views via the controllers to the models, where the models update themselves, and then update the controllers which then update the views. Visually it looks like:

  View receives event-------\..../----views render new state
  Controllers handle event---\../--controllers mediate new state
  Models react to new data----\/--models update controllers
The Sproutcore javascript MVC framework espouses this, for example, and I'm sure many other MVC frameworks do too.

I'd be really interested to see how Flux would augment statecharts...



I should have added - these are the only actions you can take at each level, so no arbitrary updating of views when you're in the left-hand side of the controller stage, for example. That stops the arbitrary circular information flows cited in the flux introduction.




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

Search: