I have an issue with Knockout where I prototype a user object where the observable properties of my object seem to be overwritten by the last occurrence.
Therefore I cannot use the same object more than once otherwise it will be overwritten.
Although this is hard to explain, see my fiddle.
What am I doing wrong? (or is this a bug in Knockout?) How can I fix the problem.
Because observables are functions and not properties they are represented by a single instance on the object prototype, unlike properties which will be created on the object when they are set.
You could use functional inheritance to achieve what you want.
http://jsfiddle.net/ypWQN/1/
Hope this helps.