time_plus
Extensions for DateTime and Duration to easily add, convert, and work with time in Dart.
1.3.2
2.6K downloads/mo
#4902 most downloaded on pub.dev
jozzdart/time_plus
What this package is like to depend on
Last release 1 years ago
28 May 2025
Too new to tell
only 1 release windows
Nearly every release is documented
notes for 7 of 7 stable releases
Nothing withdrawn
no release was ever pulled
1 years old
7 releases · first in 2025
0 releases in the last 12 months
see the full history below
Release timeline
7 releases · May 2025 to May 2025Releases
latest 7-
1.3.228 May 2025 -
1.3.124 May 2025 -
1.3.024 May 2025Release notes
Open source →- Added full suite of
Duration→ fractional unit getters:asMilliseconds,asSeconds,asMinutes,asHours,asDays,asWeeks,asMonths,asYears,asDecades,asCenturies
- Added new
DateTimecalendar-aware getters:daysInMonth,daysInYear
- Added smart
Durationcreation fromintanddouble:1.days,2.hours,3.centuriesand1.5.hours,0.25.years,2.75.months, etc. Uses decomposition for precise accuracy.
- Updated month/year/decade/century logic for
Duration:- Now uses long-term Gregorian calendar averages:
- Month ≈ 30.436875 days
- Year ≈ 365.2425 days
- Decade ≈ 3,652.425 days
- Century ≈ 36,524.25 days
- Improves consistency, accuracy, and alignment with real-world time math
- Replaces prior approximations (
30,365,3650, etc.)
- Now uses long-term Gregorian calendar averages:
- Added
time vs time_pluscomparison section to README:- Highlights architectural improvements, precision gains, and test coverage
- Documents why
time_plusis a modern, high-performance alternative to thetimepackage
All new additions are documented in the README and covered by tests.
For exact calendar logic, continue usingDateTimemethods.Release notes
Open source →- Added full suite of
Duration→ fractional unit getters:asMilliseconds,asSeconds,asMinutes,asHours,asDays,asWeeks,asMonths,asYears,asDecades,asCenturies
- Added new
DateTimecalendar-aware getters:daysInMonth,daysInYear
- Added smart
Durationcreation fromintanddouble:1.days,2.hours,3.centuriesand1.5.hours,0.25.years,2.75.months, etc. Uses decomposition for precise accuracy.
- Updated month/year/decade/century logic for
Duration:- Now uses long-term Gregorian calendar averages:
- Month ≈ 30.436875 days
- Year ≈ 365.2425 days
- Decade ≈ 3,652.425 days
- Century ≈ 36,524.25 days
- Improves consistency, accuracy, and alignment with real-world time math
- Replaces prior approximations (
30,365,3650, etc.)
- Now uses long-term Gregorian calendar averages:
- Added
time vs time_pluscomparison section to README:- Highlights architectural improvements, precision gains, and test coverage
- Documents why
time_plusis a modern, high-performance alternative to thetimepackage
All new additions are documented in the README and covered by tests.
For exact calendar logic, continue usingDateTimemethods. - Added full suite of
-
1.2.023 May 2025Release notes
Open source →- Added comprehensive
DateTimesubtraction extensions with calendar-aware date arithmetic - Added
DateTimeSubtractMonthsAndYearsExtensionwithsubtractMonths,subtractYears,subtractMonth,subtractYearmethods - Added
DateTimeSubtractExtendingYearsExtensionwithsubtractDecades,subtractCenturies,subtractDecade,subtractCenturymethods - Works better than "adding minus days" or "adding minus weeks"
- Lowered Dart SDK constraint to
>=2.12.0 <4.0.0for wider compatibility
Release notes
Open source →- Added comprehensive
DateTimesubtraction extensions with calendar-aware date arithmetic - Added
DateTimeSubtractMonthsAndYearsExtensionwithsubtractMonths,subtractYears,subtractMonth,subtractYearmethods - Added
DateTimeSubtractExtendingYearsExtensionwithsubtractDecades,subtractCenturies,subtractDecade,subtractCenturymethods - Works better than "adding minus days" or "adding minus weeks"
- Lowered Dart SDK constraint to
>=2.12.0 <4.0.0for wider compatibility
- Added comprehensive
-
1.1.622 May 2025Release notes
Open source →- Added
DateTimeNextExtensionsextension onDateTimeclass:- Advanced date navigation methods:
nextWeekdayTime: Find the next occurrence of a specific weekday with optional timenextTimeOfDay: Find the next time matching a specific time of day
- Advanced date navigation methods:
Release notes
Open source →- Added
DateTimeNextExtensionsextension onDateTimeclass:- Advanced date navigation methods:
nextWeekdayTime: Find the next occurrence of a specific weekday with optional timenextTimeOfDay: Find the next time matching a specific time of day
- Advanced date navigation methods:
- Added
-
1.1.522 May 2025Release notes
Open source →- Added
DateTimeWeekdayExtensionsextension onDateTimeclass:- Day navigation getters:
yesterday: Returns start of previous daytomorrow: Returns start of next day
- Weekday navigation getters:
nextWeekday: Returns weekday number of next daypreviousWeekday: Returns weekday number of previous day
- Day navigation getters:
Release notes
Open source →- Added
DateTimeWeekdayExtensionsextension onDateTimeclass:- Day navigation getters:
yesterday: Returns start of previous daytomorrow: Returns start of next day
- Weekday navigation getters:
nextWeekday: Returns weekday number of next daypreviousWeekday: Returns weekday number of previous day
- Day navigation getters:
- Added
-
1.1.422 May 2025Release notes
Open source →Added detailed README for enhanced user experience.
Added
- README with:
- Emoji-based Table of Contents
- Categorized DateTime and Duration extensions
- Code examples for features
- Emoji icons for readability
- "Back to Top" links
- Sections on:
- DateTime: Time units, precision, boundaries, leap year
- Duration: Time units, factory methods, conversion, breakdown, removal
- Examples with use cases, edge cases, chainable operations, calendar-aware calculations
- Support: License, support link, branding
- README with: