Skip to content
This repository has been archived by the owner on Feb 7, 2024. It is now read-only.

Add @ProvideReactive and @InjectReactive decorators #205

Merged
merged 3 commits into from
Jun 11, 2019

Conversation

smithki
Copy link
Contributor

@smithki smithki commented May 24, 2019

Based on the request in #39
I thought this would be a nice feature to have, so I took a crack at implementing it. If this is acceptable to merge, I'm happy to add documentation to the README!

One gotcha...
When using @ProvideReactive with @Prop, you must use @Injectnot @InjectReactive—to use the injected property as a default... see the coverage for an example of this.

@smithki smithki marked this pull request as ready for review May 24, 2019 05:29
@smithki smithki changed the title Add "ProvideReactive" and "InjectReactive" decorators Add @ProvideReactive and @InjectReactive decorators May 24, 2019
@kaorun343
Copy link
Owner

@smithki

Hi.

Thanks for your PR. Although these newly provided decorators don't have the same name with the property names of ComponentOptions, these new features should be needed to follow the plain Vue's behavior.
I'll merge this, thanks!

@kaorun343 kaorun343 merged commit dc4ece8 into kaorun343:master Jun 11, 2019
@smithki smithki deleted the reactive-provide branch July 11, 2019 19:30
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants