Closed Fdawgs closed 1 month ago
shipped in compromise-dates 3.7.0 cheers
@spencermountain Sorry just got around testing 3.7.0. This is almost fixed, the year shifts correctly but the end date is now the first day of the month rather than the last.
June next year
:
{
start: '2024-06-01T00:00:00.000+01:00',
end: '2024-06-01T23:59:59.999+01:00', // expected '2024-06-30T23:59:59.999+01:00',
timezone: 'Europe/London',
duration: { years: 0, months: 0, days: 1, hours: 0, minutes: 0 }
}
#Month this year
and #Month last year
also has the same issue with the day no longer being the last day of the month.
Yeah. It's a little awkward. I think it's maybe library-wide. Only a millisecond, but still awkward.
You've lost me there @spencermountain.
Node version: 20.17.0 Compromise version: 14.14.0 Compromise-dates version: 3.6.0
Sorry, probably sick of all the Issues raised by me! Using the compromise-dates plugin, sentences that match
#Month (next|last) year
are projected as this year. However,(next|last) #Month
and#WeekDay (next|last) week
work as expected.Example: