copyrightYears function

String copyrightYears(
  1. DateTime now
)

2024 in 2024, 2024–2026 later: the site first went up in 2024, and a fixed year goes stale.

Implementation

String copyrightYears(DateTime now) =>
    now.year > 2024 ? '2024–${now.year}' : '2024';