Convert timestamps to relative times like '2 hours ago'

Generate relative time datelines at the Edge instead of in the browser or at origin. Better caching, faster rendering, fewer reflows.


Use this solution in your VCL service (click RUN below to test this solution or clone it to make changes):


Use this solution in your Compute service:

  1. JavaScript
  2. Rust