Skip to content

API note RE: extracting the source plain data object via JSON parse/stringify #171

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

Merged
merged 2 commits into from
Nov 20, 2015
Merged

Conversation

furey
Copy link
Contributor

@furey furey commented Oct 31, 2015

No description provided.

@furey furey changed the title API note RE: extracting the source plain data object via JSON parse/stringify. API note RE: extracting the source plain data object via JSON parse/stringify Oct 31, 2015

Properties that start with `_` or `$` will **not** be proxied on the Vue instance because they may conflict with Vue's internal properties and API methods. You will have to access them as `vm.$data._property`.

If required, the original **plain** data object can be extracted by passing `vm.$data` through `JSON.parse(JSON.stringify(...))`.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We are not really extracting the "original object" - the original object is the data object. What you get from JSON.parse(JSON.stringify()) is in fact a deep clone of the original object.

yyx990803 added a commit that referenced this pull request Nov 20, 2015
API note RE: extracting the source plain data object via JSON parse/stringify
@yyx990803 yyx990803 merged commit c429ee1 into vuejs:master Nov 20, 2015
kazupon pushed a commit to kazupon/vuejs.org that referenced this pull request Oct 2, 2016
* transtale forms

* fix
lex111 pushed a commit to lex111/vuejs.org that referenced this pull request Feb 3, 2018
isatrio pushed a commit to isatrio/vuejs.org that referenced this pull request Oct 27, 2019
[Performance Benchmark Page] - TodoMVC - translated
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.

2 participants