ember.js - Ember-CLI: Initializers and and Initializer subclass -
currently, in ember-cli initializer defined so:
// app/initializers/observation.js export default { name: 'observation', initialize: function() { // code } };
in case, how define sub-class of initializer... following code correct?
// app/initializers/close-observation.js export default ember.observation.extend{ newproperty: 1, otherproperties: 2 };
just import base initializer variable , extend that.
import observation './observation'; export default observation.extend{ newproperty: 1, otherproperties: 2 };
Comments
Post a Comment