[wp-trac] [WordPress Trac] #39222: Add JavaScript date helpers

WordPress Trac noreply at wordpress.org
Thu Jan 12 05:27:45 UTC 2017

#39222: Add JavaScript date helpers
 Reporter:  rmccue           |       Owner:
     Type:  feature request  |      Status:  new
 Priority:  normal           |   Milestone:  4.8
Component:  Date/Time        |     Version:  4.7
 Severity:  normal           |  Resolution:
 Keywords:  needs-patch      |     Focuses:  rest-api

Comment (by rmccue):

 It's more that we need to have a consistent translation platform across
 all of WordPress (see #20491). We can integrate the two, but we ''also''
 need to ensure that the date formatting settings are also respected. In
 particular, the Date and Time formats from the General Settings page need
 to be handled, which requires mapping from [https://php.net/date PHP date
 codes]. There are also a bunch of other pieces which change date
 formatting dependent on the locale (see `date_i18n()`).

 While it is less work immediately to use Moment's locales, we would then
 have two translation tools to maintain, and which may not be in sync. This
 also increases the maintenance burden for the translation teams. It's
 worth the additional effort to have a consistent set of translations for

 That's not to say we shouldn't add Moment, but if we do, we need to be
 considered and purposeful in how we handle adding it, it's not just a

Ticket URL: <https://core.trac.wordpress.org/ticket/39222#comment:7>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform

More information about the wp-trac mailing list