The road to 2.0.0
This patch release deprecates the use of injectionFactories. Automatic injection is an anti-pattern that we are removing with this release, in favor of explicitly injecting the flashMessages service into the things that need it.
Automatic injection will be removed in 2.0.0.
To prepare for the upgrade and fix deprecation warnings, simply directly inject the service into your classes and remove the injectionFactories config (if any):
// foo-bar/component.js
export default Ember.Component.extend({
flashMessages: Ember.inject.service(),
actions: {
foo() { return Ember.get(this, 'flashMessages').success('foobar'); }
}
});// config/environment.js
module.exports = function(environment) {
var ENV = {
flashMessageDefaults: {
// remove `injectionFactories`
}
}
}