Add RFC for deprecation Ember Data initializers#181
Conversation
230e0e4 to
919279f
Compare
| `transforms`, and `store` Ember initializers that Ember Data injects | ||
| into apps. The `ember-data` initializer not be changed and any code | ||
| that previously depended on the ordering of these initializers (via | ||
| the `before` or `after` properties on an initalizer) will can be |
| # Summary | ||
|
|
||
| The goal of this RFC is to remove the `data-adapter`, `injectStore`, | ||
| `transforms`, and `store` Ember initializers that Ember Data injects |
There was a problem hiding this comment.
possibly better to refer to them as application/application instance initializers?
|
|
||
| # Motivation | ||
|
|
||
| The intializes `data-adapter`, `injectStore`, `transforms`, and |
| `store` have not been used by Ember Data since | ||
| [Apr 8, 2014](https://github.com/emberjs/data/commit/d25e23f622a3677b8372db535b2ab824ad306a16). However, | ||
| they are still injected into every Ember app that depends on Ember | ||
| Data because existing apps may have depending on these initializers |
| Data needs to support. | ||
|
|
||
| Since these initializers are noop functions that run after the | ||
| `ember-data` initializer. Any initializers that depends on one of the |
| # Detailed design | ||
|
|
||
| Ember Data's instance initializer will start checking for any | ||
| initializers who's `before` or `after` properties depend on one of |
| Ember Data's instance initializer will start checking for any | ||
| initializers who's `before` or `after` properties depend on one of | ||
| these deprecated initalizer. If it finds an initalizer that references | ||
| one of the deprecated initalizers Ember Data will then log a |
| # How We Teach This | ||
|
|
||
| This change should have no impact on how we teach Ember or Ember | ||
| Data. The initalizers that will be remove have been unused for a long |
There was a problem hiding this comment.
Muphry's law kicking in here ... "removed" ![]()
| removed. | ||
|
|
||
|
|
||
| # How We Teach This |
There was a problem hiding this comment.
could we come up with a codemod?
|
|
||
| Users who need to run initalizer code before or after Ember Data | ||
| injects the store into routes should be taught to use `before: | ||
| 'ember-data'`, or `after: 'ember-data'` on there initalizers. |
|
@bmac as done in https://github.com/cibernox/rfcs/blob/deprecate-ember-k/text/0000-deprecate-ember-k.md#addenda, I would like to suggestion reaching out to EmberObserver and get some usage statistics across published addons (worried about outdated dependencies), and coming up with a codemod, if possible. Looking good! |
|
@locks I checked out all of the Ember Data Adapters and Ember Data Extensions form Ember observer and found the following adapters referencing the deprecated initializers. |
|
|
||
| The goal of this RFC is to remove the `data-adapter`, `injectStore`, | ||
| `transforms`, and `store` Ember application initializers that Ember Data injects | ||
| into apps. The `ember-data` initializer not be changed and any code |
|
The Ember Data team has reviewed this proposal and have decided to move it to the Final Comment Period! If no new significant concerns are raised, in one week's time this proposal will be officially merged. |
Rendered.
Known usage (checked for PR sent)
Todo