1ec5 left a comment (openstreetmap/openstreetmap-website#6534)
Yes, we can avoid a user-perceptible relayout by hooking into the
[`DOMContentLoaded`](https://developer.mozilla.org/en-US/docs/Web/API/Document/DOMContentLoaded_event)
event. If we were to do a lot of work in the event handler, the user would
notice a delayed relayout, but we hardly use this hook for anything yet, and
replacing the contents of a few `<time>` tags with formatted dates would be
very efficient.
I think this would be easier than ensuring consistency between server- and
client-formatted timestamps. As far as I can tell, rails-i18n is one of the few
popular internationalization libraries these days that doesn’t directly use
CLDR for date formats or their translations.
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/issues/6534#issuecomment-3560009772
You are receiving this because you are subscribed to this thread.
Message ID:
<openstreetmap/openstreetmap-website/issues/6534/[email protected]>
_______________________________________________
rails-dev mailing list
[email protected]
https://lists.openstreetmap.org/listinfo/rails-dev