Copied from Knockout's example, and started refactoring for Consistent.js
Some more features implemented