mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-15 11:34:24 +03:00
49ea71ed4f
- Change fixture response of posts route to actual format. - Extracted classNames logic of routes into style-body mixin. - Additionally replaced all double-quotes with single-quotes for style conformance.
9 lines
439 B
JavaScript
9 lines
439 B
JavaScript
/* global moment */
|
|
var formatTimeago = Ember.Handlebars.makeBoundHelper(function (timeago) {
|
|
return moment(timeago).fromNow();
|
|
// stefanpenner says cool for small number of timeagos.
|
|
// For large numbers moment sucks => single Ember.Object based clock better
|
|
// https://github.com/manuelmitasch/ghost-admin-ember-demo/commit/fba3ab0a59238290c85d4fa0d7c6ed1be2a8a82e#commitcomment-5396524
|
|
});
|
|
|
|
export default formatTimeago; |