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

Sounds similar to the Pyramid web framework for Python, which skips controllers too:

http://docs.pylonsproject.org/projects/pyramid/en/1.2-branch...

I prefer this approach over the usual web-mvc. It's important to note that a view is not a template, but something that generates output. In Pyramid, it's usually a function that passes data to the template (which generates html) or produces JSON from native types.



Django also calls the functions/classes where you define the logic of selecting the models to operate on, validate, pick output, etc… a 'view'. The template where you map the data to html is just that: a template. People coming to Django from Rails often get confused by that. In the end, it's very similar but with a different name.

I'm reminded of the old Microsoft Foundation Classes with their Document-Object model that lacked a controller. Their promise was that you could reuse views and documents but in practice the lack of a controller to handle user input meant you never could. At least, I never could.




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

Search: