PERF: reduces rendering time of local-dates (PR #13931)

  • prefers insertAdjacentHTML over innerHTML as it’s much faster in this case (about 5x)
  • memoizes tz.guess()
  • memoizes list of timezones
  • inlines template
  • applies main element class in one pass

The perf profile for 78 dates before, notice the innerHTML timing:

After:

GitHub

:rocket: