Skip to content

Correctly format dates with specified time zone - #873

Merged
paulrobertlloyd merged 2 commits into
mainfrom
fix/861-format-date-with-time-zone
Aug 15, 2026
Merged

Correctly format dates with specified time zone#873
paulrobertlloyd merged 2 commits into
mainfrom
fix/861-format-date-with-time-zone

Conversation

@paulrobertlloyd

@paulrobertlloyd paulrobertlloyd commented Aug 15, 2026

Copy link
Copy Markdown
Collaborator

Fixes #861.

Plain date-fns v4's format() doesn't recognise a timeZone option, it only respects time zones via the in: tz(timeZone) option from @date-fns/tz.

The regression was introduced in commit 0d972ee. This updated formatDateToLocal and getDate to use the new in: tz() pattern, but missed formatDate.

This PR also fixes a typo where locale was being passed from a non-existent application.locals option.

@paulrobertlloyd paulrobertlloyd added plugin-endpoint Endpoint plug-in core Core indiekit package labels Aug 15, 2026
@paulrobertlloyd
paulrobertlloyd merged commit beda3c0 into main Aug 15, 2026
1 check passed
@paulrobertlloyd
paulrobertlloyd deleted the fix/861-format-date-with-time-zone branch August 15, 2026 18:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

core Core indiekit package plugin-endpoint Endpoint plug-in

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Hour path tokens not reflecting timeZone setting

1 participant