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

Provide isn't reactive with a single array #5223

Closed
ralphchristianeclipse opened this issue Mar 19, 2017 · 1 comment
Closed

Provide isn't reactive with a single array #5223

ralphchristianeclipse opened this issue Mar 19, 2017 · 1 comment
Labels

Comments

@ralphchristianeclipse
Copy link

Version

2.2.4

Reproduction link

http:https://codepen.io/anon/pen/VpyqEz?editors=1111

Steps to reproduce

Create a parent and child component

Set the provide of the parent using vuex

Inject the provide of the parent to child

What is expected?

Must be reactive

What is actually happening?

Not Reactive

@posva posva changed the title Provide isn't reactive with Vuex Provide isn't reactive with a single array Mar 19, 2017
@posva
Copy link
Member

posva commented Mar 19, 2017

It actually doesn't depend on Vuex. It happens with plain Vue: http:https://codepen.io/anon/pen/EWoMLr?editors=1111

Using a single array, nothing is tracked. But if we display another injected property (in this case bar), both are updating accordingly

Kingwl added a commit to Kingwl/vue that referenced this issue Mar 20, 2017
awamwang pushed a commit to awamwang/vue that referenced this issue Jun 15, 2017
* fix provide isn't reactive with a single array - Fix vuejs#5223

* add warning when injections has been modified
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants