Closed aaronlelevier closed 5 years ago
This is desired behavior.
Have a look at the documentation here: https://github.com/stefanpenner/ember-moment#moment
Your first example should be read as:
{{moment 'this is my date value' 'this is the format of my date'}}
The output will always be in the default format. If you just want to format a date, use {{moment-format}}
And your second example should be read as:
{{moment-format 'this is my date value' 'this is the format how the output should look like'}}
And if your date has a special format, use the third parameter for this handlebar to define that also.
See https://github.com/stefanpenner/ember-moment#moment-format
The readme example with
moment
only doesn't seem to apply formatting. Example from README:Results in
Mon Nov 05 2018 00:00:00 GMT-0800
With
moment-format
this works.Results in:
2018-11-05