fix(deps): update dependency date-fns to v4#472
Open
renovate[bot] wants to merge 1 commit into
Open
Conversation
367db0d to
acf7222
Compare
6b523d8 to
7a37d79
Compare
7a37d79 to
e9cb69b
Compare
e9cb69b to
17be9ae
Compare
17be9ae to
c2f892e
Compare
c2f892e to
bd6ad6a
Compare
bd6ad6a to
f39dd3c
Compare
7b13258 to
4d603d2
Compare
|
4d603d2 to
9520114
Compare
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



This PR contains the following updates:
3.6.0→4.4.0Release Notes
date-fns/date-fns (date-fns)
v4.4.0Compare Source
This release revisits the approach to CDN usage and introduces a new package,
@date-fns/cdnand deprecates thedate-fnsCDN scripts. It allowed reducing the zipped package size from5.83 MBdown to3.96 MBwithout introducing any breaking changes.In
v5.0.0-alpha.0where CDN scripts are completely removed fromdate-fnsthe change is more significant and brings the zipped package size down to2.89 MB.It is just the first step in optimizing the package size. Expect further size reduction in the future v4 and v5 versions.
Changed
DEPRECATED: The
date-fnsCDN scripts are now deprecated and will be removed in the next major release. Please switch to the new@date-fns/cdnpackage for CDN usage.Removed CDN source maps to reduce the package size. If you rely on them, please switch to the new
@date-fns/cdnpackage that still includes them.v4.3.0Compare Source
Kudos to @ImRodry and @puneetdixit200 for their contributions.
Fixed
Fixed missing modularized optimization fallback (for Next.js and others). See #4193.
Fixed
ptlocale first day of week to be Sunday. See #4195 by @ImRodry.Fixed
zh-CN,zh-HK, andzh-TWlocale month parsing for October, November, and December. See #4194 by @puneetdixit200.v4.2.1Compare Source
Fixed
v4.2.0Compare Source
This is a minor release in all senses, it only includes documentation updates (first of many) that points to the new You Don't Need date-fns* page.
* Not really
Changed
add,addBusinessDays, andaddDays.v4.1.0Compare Source
This release adds time zone support to format functions (that I somehow missed when working on the feature) and fixes a few bugs.
Make sure also upgrade
TZDateto v1.0.2 as it includes a bunch of critical bug fixes.Fixed
constructFromthrowing an exception onnullarguments. Whilenullisn't allowed, the functions should rather returnInvalid DateorNaNin such cases. See #3885.Added
format,formatISO,formatISO9075,formatRelativeandformatRFC3339. See #3886.v4.0.0Compare Source
I have great news! First, ten years after its release, date-fns finally gets first-class time zone support.
Another great news is that there aren't many breaking changes in this release. All of them are type-related and will affect only those explicitly using internal date-fns types. Finally, it has been less than a year since the last major release, which is an improvement over the previous four years between v2 and v3. I plan on keeping the pace and minimizing breaking changes moving forward.
Read more about the release in the announcement blog post.
- Sasha @kossnocorp
Added
Added time zones support via
@date-fns/tz'sTZDateclass andtzhelper function. See its README for the details about the API.All relevant functions now accept the context
inoption, which allows to specify the time zone to make the calculations in. If the function also returns a date, it will be in the specified time zone:In the example,
addDayswill get the current date and time in Singapore and add 5 days to it.startOfDaywill inherit the date type and return the start of the day in Singapore.Changed
The function arguments, as well as
Interval'sstartandend, now can be of different types, allowing you to mixUTCDate,TZDate,Date, and other extensions, as well as primitives (strings and numbers).The functions will normalize these values, make calculations, and return the result in the same type, preventing any bugs caused by the discrepancy. If passed, the type will be inferred from the context
inoption or the first encountered argument object type. TheInterval'sstartandendwill be considered separately, starting fromstart.In the given example, the result will be in the
TZDateas the first argument is a number, and thestarttakes precedence over theend.BREAKING: This release contains a bunch of types changes that should not affect the library's expected usage. The changes are primarily internal and nuanced, so rather than listing them here, I recommend you running the type checker after the upgrade. If there are unfixable problems, please open an issue.
BREAKING: The package now is ESM-first. The CommonJS is still support and It should not affect most users, but it might break in certains environments. If you encounter any issues, please report them.
Fixed
$by properly wrapping the code in an IIFE.Configuration
📅 Schedule: (in timezone Europe/London)
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.