-
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Move Equals
constraint into an intersection type.
#2123
Move Equals
constraint into an intersection type.
#2123
Conversation
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit ca9aa48:
|
Thanks, Daniel! This is only in our test suite, so it shouldn't be a user-facing issue, but I very much appreciate the attention to detail on your end and the PR! |
React Redux and Reselect don't use RTK on the other hand does, and this suggestion seems to break the expected behaviour of the utility. As per reduxjs/redux-toolkit@1ae8a62 it appears some errors we want to be raised are no longer raised. Here's a quick reproduction: https://tsplay.dev/NVePlw |
@EskiMojo14 looks like this is from use of Let me know if that works! |
that seems to do the trick, thanks! in the slightly more long term I think we'll switch to vitest's type test utilities, so hopefully those will continue to work :) |
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [react-redux](https://github.com/reduxjs/react-redux) | [`^9.1.0` -> `^9.1.1`](https://renovatebot.com/diffs/npm/react-redux/9.1.0/9.1.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/react-redux/9.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/react-redux/9.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/react-redux/9.1.0/9.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/react-redux/9.1.0/9.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>reduxjs/react-redux (react-redux)</summary> ### [`v9.1.1`](https://github.com/reduxjs/react-redux/releases/tag/v9.1.1) [Compare Source](https://github.com/reduxjs/react-redux/compare/v9.1.0...v9.1.1) This bugfix release fixes an issue with `connect` and React Native caused by changes to our bundling setup in v9. Nested `connect` calls should work correctly now. #### What's Changed - Remove unused isProcessingDispatch by [@​Connormiha](https://github.com/Connormiha) in [https://github.com/reduxjs/react-redux/pull/2122](https://github.com/reduxjs/react-redux/pull/2122) - Move `Equals` constraint into an intersection type. by [@​DanielRosenwasser](https://github.com/DanielRosenwasser) in [https://github.com/reduxjs/react-redux/pull/2123](https://github.com/reduxjs/react-redux/pull/2123) - Fix `useIsomorphicLayoutEffect` usage in React Native environments by [@​aryaemami59](https://github.com/aryaemami59) in [https://github.com/reduxjs/react-redux/pull/2156](https://github.com/reduxjs/react-redux/pull/2156) **Full Changelog**: reduxjs/react-redux@v9.1.0...v9.1.1 </details> --- ### Configuration 📅 **Schedule**: Branch creation - "after 5pm,every weekend" in timezone America/Los_Angeles, Automerge - "after 5pm,every weekend" in timezone America/Los_Angeles. 🚦 **Automerge**: Enabled. ♻ **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. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://developer.mend.io/github/valora-inc/wallet). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4zMDEuNCIsInVwZGF0ZWRJblZlciI6IjM3LjMwMS40IiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJucG0iLCJyZW5vdmF0ZSJdfQ==--> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [react-redux](https://github.com/reduxjs/react-redux) | [`^9.1.0` -> `^9.1.1`](https://renovatebot.com/diffs/npm/react-redux/9.1.0/9.1.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/react-redux/9.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/react-redux/9.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/react-redux/9.1.0/9.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/react-redux/9.1.0/9.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>reduxjs/react-redux (react-redux)</summary> ### [`v9.1.1`](https://github.com/reduxjs/react-redux/releases/tag/v9.1.1) [Compare Source](https://github.com/reduxjs/react-redux/compare/v9.1.0...v9.1.1) This bugfix release fixes an issue with `connect` and React Native caused by changes to our bundling setup in v9. Nested `connect` calls should work correctly now. #### What's Changed - Remove unused isProcessingDispatch by [@​Connormiha](https://github.com/Connormiha) in [https://github.com/reduxjs/react-redux/pull/2122](https://github.com/reduxjs/react-redux/pull/2122) - Move `Equals` constraint into an intersection type. by [@​DanielRosenwasser](https://github.com/DanielRosenwasser) in [https://github.com/reduxjs/react-redux/pull/2123](https://github.com/reduxjs/react-redux/pull/2123) - Fix `useIsomorphicLayoutEffect` usage in React Native environments by [@​aryaemami59](https://github.com/aryaemami59) in [https://github.com/reduxjs/react-redux/pull/2156](https://github.com/reduxjs/react-redux/pull/2156) **Full Changelog**: reduxjs/react-redux@v9.1.0...v9.1.1 </details> --- ### Configuration 📅 **Schedule**: Branch creation - "after 5pm,every weekend" in timezone America/Los_Angeles, Automerge - "after 5pm,every weekend" in timezone America/Los_Angeles. 🚦 **Automerge**: Enabled. ♻ **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. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://developer.mend.io/github/valora-inc/wallet). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4zMDEuNCIsInVwZGF0ZWRJblZlciI6IjM3LjMwMS40IiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJucG0iLCJyZW5vdmF0ZSJdfQ==--> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [react-redux](https://github.com/reduxjs/react-redux) | [`^9.1.0` -> `^9.1.1`](https://renovatebot.com/diffs/npm/react-redux/9.1.0/9.1.1) | [![age](https://developer.mend.io/api/mc/badges/age/npm/react-redux/9.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/react-redux/9.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/react-redux/9.1.0/9.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/react-redux/9.1.0/9.1.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>reduxjs/react-redux (react-redux)</summary> ### [`v9.1.1`](https://github.com/reduxjs/react-redux/releases/tag/v9.1.1) [Compare Source](https://github.com/reduxjs/react-redux/compare/v9.1.0...v9.1.1) This bugfix release fixes an issue with `connect` and React Native caused by changes to our bundling setup in v9. Nested `connect` calls should work correctly now. #### What's Changed - Remove unused isProcessingDispatch by [@​Connormiha](https://github.com/Connormiha) in [https://github.com/reduxjs/react-redux/pull/2122](https://github.com/reduxjs/react-redux/pull/2122) - Move `Equals` constraint into an intersection type. by [@​DanielRosenwasser](https://github.com/DanielRosenwasser) in [https://github.com/reduxjs/react-redux/pull/2123](https://github.com/reduxjs/react-redux/pull/2123) - Fix `useIsomorphicLayoutEffect` usage in React Native environments by [@​aryaemami59](https://github.com/aryaemami59) in [https://github.com/reduxjs/react-redux/pull/2156](https://github.com/reduxjs/react-redux/pull/2156) **Full Changelog**: reduxjs/react-redux@v9.1.0...v9.1.1 </details> --- ### Configuration 📅 **Schedule**: Branch creation - "after 5pm,every weekend" in timezone America/Los_Angeles, Automerge - "after 5pm,every weekend" in timezone America/Los_Angeles. 🚦 **Automerge**: Enabled. ♻ **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. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://developer.mend.io/github/valora-inc/wallet). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4zMDEuNCIsInVwZGF0ZWRJblZlciI6IjM3LjMwMS40IiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJucG0iLCJyZW5vdmF0ZSJdfQ==--> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
In microsoft/TypeScript#57117, we noticed that react-redux's build is impacted by a change in in microsoft/TypeScript#56515. What this means is that TypeScript 5.4, you'll get an error in
expectExactType
.The solution I would suggest for now is to just make
U
extendT
and move the constraint to an intersection wherever you useU
.