View (in MVC) should contain minimal logic

29 Nov 2011

It is just amazing that I've just realized this. This week I enable my friend, a designer, to make changes to the website directly.

He has to learn the structure of Rails 3.0. But it's merely views' structures though. This is to take the burden out of me.

Previously, he would make changes in a static HTML and I would migrate those changes to the website. It was indeed a really painful process because I have to look at 2 HTML pages and try to map the changes.

Then, it strikes me that this is a functional reason why a view should not contain any logic or computation.

A view should be so clean that your designer can understand it.

If your designer can make changes to the website directly, then the process of building a website is just much faster and painless for everyone.

Give it a kudos