chore(deps): update dependency material-ui-confirm to v4 - autoclosed #173
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
->^4.0.0
Release Notes
jonatanklosko/material-ui-confirm (material-ui-confirm)
v4.0.0
Compare Source
This release changes the API, affecting all usages of⚠️ .
confirm
function. Previously the promise returned byconfirm
would be resolved on confirm and rejected on cancel. This has changed and the promise is now always resolvedYou can upgrade to the new version and maintain the previous behaviour by setting a provider attribute:
Migrating
Given this code from v3:
You can achieve the same behaviour in v4, like so:
The promise is also resolved on natural close (backdrop click, escape) or when the parent unmounts, in both cases with a distinct
reason
. In most cases you may only be interested in the confirmed code path, in which case you would only checkconfirmed
and ignore thereason
.With this new API, it is guaranteed the callback eventually runs, which helps to avoid leaks if the callback is supposed to free certain resources. It is also more suitable for use with
async
/await
(which required atry
/catch
):Breaking changes
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, 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.