ember-moment
ember-moment copied to clipboard
Environment configuration does not work as documented
The README.md
shows the following example configuration for the allowEmpty
option:
// config/environment.js
module.exports = function() {
return {
moment: {
allowEmpty: true // default: false
}
}
};
However, this does not seem to work for me, unless I change the key from moment
to 'ember-moment'
like this:
// config/environment.js
module.exports = function() {
return {
'ember-moment': {
allowEmpty: true // default: false
}
}
};
Additionally, the application config appears to point to ember-moment
as the expected key in multiple places:
- https://github.com/adopted-ember-addons/ember-moment/blob/c80dd174c034d1ad62d2e016ea46d7de05d4cf98/src/services/moment.js#L23
- https://github.com/adopted-ember-addons/ember-moment/blob/c80dd174c034d1ad62d2e016ea46d7de05d4cf98/test-app/config/environment.js#L9
Am I missing something? Or should we update the README from moment
to 'ember-moment'
?
I'm experiencing this as well (ember-moment v10.0.0
). Config in config/environment.js
is not picked up by key moment
, but ember-moment
. May I suggest broadening the title of this issue @mayatron ?
I'm experiencing this as well (
ember-moment v10.0.0
). Config inconfig/environment.js
is not picked up by keymoment
, butember-moment
. May I suggest broadening the title of this issue @mayatron ?
Done!