NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
pub.dev · #3092 most downloaded on pub.dev
Multi-purpose immutable DateTime subclass. Supports multiple localizations to easily convert DateTime and Duration into human-readable format
Last release 5 months ago
03 May 2026
Release timing varies
gaps range from 8 days to 4 months
Nearly every release is documented
notes for 60 of the last 60 stable releases
3 versions withdrawn
withdrawn after publishing
5 years old
86 releases · first in 2022
Added .differenceInDays(other) function
.differenceInDays(other) functionDurationExtra extension on DurationRemoved following deprecated methods: Moment.lastMondayAsDateTime(), Moment.lastSundayAsDateTime()
MomentLocalization has gotten major updates, making it easier to implmement new localizations:
.calendar(...)calendarData, weekdayName, overrideFormattersFormatterTokenMoment.lastMondayAsDateTime(), Moment.lastSundayAsDateTime().endOf(DurationUnit unit), and it's children .endOf~~~(). Works on both Moment and DateTimeenableDebugPrint()One column per quarter.
Added shorthand function for commonly used tokens. For example, moment.LT, moment.LTS, moment.L, etc.
- Updated README.md
README.mdMoment.format() no longer has required positional argument. Optional positional argument defaults to l;
Moment.format() no longer has required positional argument. Optional positional argument defaults to l;*IMPORTANT CHANGE*: Now Moment extends DateTime class
Moment extends DateTime classDateTime and Moment. Part of MomentBenefits extension.lastWeekday(int weekday), and it's children .lastMonday(), .lastTuesday(), ..., .lastSunday(). You can also do same thing to find future weekdays. For example, .nextMonday(). Works on both Moment and DateTime.startOf(DurationUnit unit), and it's children .startOf~~~(). Works on both Moment and DateTimeNow Mongolian singular units include number 1 as nature of the language is not similar to English. For example, минутын өмнө => 1 минутын өмнө
1 as nature of the language is not similar to English. For example, минутын өмнө => 1 минутын өмнөmn_TM_tn)'s .relative(-) now uses Mongolian numbersFixed Mongolian mn_MN and Mongolian Script mn_TM suffixes
mn_MN and Mongolian Script mn_TM suffixes- Updated README.md
- Updated README.md
Added comparison functions (isAtSame_As(other))
isAtSame_As(other))Now it's possible to escape strings in Moment.format(). Encapsulate the text in square brackets ([]) to do so.
Moment.format(). Encapsulate the text in square brackets ([]) to do so.L to l (shortened version)Fixed number word gender-dependent suffix in Mongolian languages. (mn_MN, mn_MN traditional mongolian)
mn_MN, mn_MN traditional mongolian)Made major fixes in de_DE localization
de_DE localizationDateTime functions in Moment classMomentBenefits extension functions in Moment classFixed Yesterday/Tomorrow calculation. It was horrible :(((
Now localizations are listed as static functions in MomentLocalizations class. Providing easier access
MomentLocalizations class. Providing easier accessko_KO, de_DE localizationsNo longer prints the matched tokens
Removed debug prints when using .format(String payload). You can re-enable it by calling .enableDebugPrint() on the Moment instance
.format(String payload). You can re-enable it by calling .enableDebugPrint() on the Moment instancelocalizationDefaultDateFormat(), localizationDefaultHourFormat() from MomentLocalization in favor of localization aware formatterAdded MomentBenefits extenstion usage on README
- Exposed the MomentLocalization
MomentLocalizationExposed the localization in Moment class
Moment classDateTime.toMoment({MomentLocalization: localization}) function as extension on DateTimeExported localizations to localizations/all.dart, and exposed it in the main file
localizations/all.dart, and exposed it in the main fileStarted work of Korean (ko_KO) and German (de_DE) localizations
Localization to MomentLocalization for the sake of universeImproved Moment.format tokenization
Moment.format tokenizationMoment.calender now allows customFormat, which can be used instead of the localization's default format.Fixed negative sign appearing in relative date texts
Moment.format function- Initial beta release.
Your coding agent can read these notes before it upgrades. Set up the MCP server →