I am migrating an Ember rc7 project to Ember 1.0.0. I have this unusual error:
Ember.State has been moved into a plugin: https://github.com/emberjs/ember-states
I have the error only if I use a combination of Ember.js 1.0.0 in combination with Ember data 0.13. If I include the extra ember-states lib, then everything works fine.
What is the reason of this change ? Why do I need an additional lib ?
If I use Ember.js 1.0.0 in combination with Ember data 1.0.0 beta.1, then this error does not occur.
I hope somebody can explain why this additional lib seems to be needed in some cases ?
Marc
According to this pull request Ember itself does not use Ember.State
internally anymore, and as of this Ember Data commit Ember Data did not depend on the Ember.State
implementation (a new/better way to handle internal state in Ember Data was used instead).
Since neither library has a dependency for Ember.State
they moved it to its own package, which can be included manually if you still require it.
Github repository for Ember.State
can be found here
Using this table you can see that when using Ember Data 0.13 and Ember 1.0.0, Ember Data 0.13 tries to use Ember.State
, but Ember 1.0.0 does not provide it and causes your error.
+-------------------------+------------------+----------------------+
| Library | Uses Ember.State | Provides Ember.State |
+-------------------------+------------------+----------------------+
| Ember rc7 | no | yes |
| Ember 1.0.0 | no | no |
| Ember Data 0.13 | yes | no |
| Ember Data 1.0.0 beta 1 | no | no |
+-------------------------+------------------+----------------------+
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With