Skip to content

[BUGFIX 3.28] Improve implicit injections deprecation for routes#19854

Merged
rwjblue merged 1 commit intoemberjs:release-3-28from
mixonic:mixonic/assert-deprecation-on-route-store
Nov 30, 2021
Merged

[BUGFIX 3.28] Improve implicit injections deprecation for routes#19854
rwjblue merged 1 commit intoemberjs:release-3-28from
mixonic:mixonic/assert-deprecation-on-route-store

Conversation

@mixonic
Copy link
Member

@mixonic mixonic commented Nov 24, 2021

The store property on routes uses a setter, and so was not impacted by the implicit-injections deprecation issued elsewhere. This may lead app or addon authors to miss usage of a deprecated store injection on the road to 4.0.

This improvement of the deprecation fidelity means libraries which use the type injection system to define a store, like Ember Data, should consider another approach to maintain any undeprecated API (for example reopening the route class).

Practically, we're not going to change the use of the injection API in Ember Data 3.28 this late, so this deprecation will log until Ember Data 4.0 is adopted by an app or all codepaths touching the injected store are avoided. With Ember and Ember Data 3.28, that would mean adding explicit model hooks on all routes with dynamic segments.

Loading
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.

3 participants