client side mvc rocks

Today I had to refactor quite a bit of code in the viewmodel of my page. Now our viewmodels contain all the logic to the page and are only connected to the view using markers such as data-bind=”click: doSomething” (knockout syntax)

Because of this decoupling I had no issues whatsoever in restructuring the code or the view as long as I adhered to the markers. Now to people having worked with webforms this may seem like a trivial thing, as you get that with the code behind model; but think of all that jquery glue that is tightly coupled to the view in your current projects. Ugh.

But best of all is the very quick feedback loop when using clientside mvc. A refresh in the browser is really all that is required to get things moving. Debugging / verification of logic is all that much easier.

Add a Comment