Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clone, not use link to object when pass it to model #27

Closed
wants to merge 1 commit into from
Closed

Clone, not use link to object when pass it to model #27

wants to merge 1 commit into from

Conversation

dmfilipenko
Copy link

I found this behaviour when we pass data to model in such way http://jsfiddle.net/4j5ZD/11/ and then change model we are change basic object

@anthonyshort
Copy link
Contributor

I actually wanted this to be how it worked since it will eventually use Object.observe. Then in this case you could do user.name = 'Barry' and it would update both views.

I think it might be best to leave it to the user to clone it if they really want different values. Unless this is presenting some pretty annoying bugs in practice.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants