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

It's not really an either or thing. You can go too far with client side rendering. But progressive enhancement can only bring you so far in delivering an interactive experience - it's typical that his example is a simple tabs implementation - of course that's easy to do without much js.

That's why I like knockoutjs - it makes it easier to sprinkle in the data-bound rich interactive UI to the pieces of your page that need it and leave the rest as normal server side rendered content. It doesn't force you to go whole hog client side.

One key area of performance where js rendered UI helps a lot is in customizing an otherwise uniformly served (and cached) page. 95% of the page is uniform to everybody, so render that server side and cache the heck out of it (varnish or whatever). Then, bind the pieces of the UI after page load and customize them based on the user - their login status, their location, etc.



Angular is also quite good about allowing you to enhance only parts of server-rendered pages.


have you actually done this? I was wondering if this is a feasible and good way to use knockout!


yeah, a good description in passing in terms of using a framework as an "island of riches" here:

http://blog.stevensanderson.com/2012/08/01/rich-javascript-a...

we use this technique at food52.com, e.g this content page cached uniformly, login system, recipe saving widget, comment system all done in ko.

http://food52.com/recipes/22888-yotam-ottolenghi-sami-tamimi...

more interactive / sophisticated uses of ko coming in our new shop soon for the cart functionality.




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

Search: