Skip to content

chore(deps): bump reselect from 3.0.1 to 4.1.3#177

Closed
dependabot[bot] wants to merge 1 commit into
masterfrom
dependabot/npm_and_yarn/master/reselect-4.1.3
Closed

chore(deps): bump reselect from 3.0.1 to 4.1.3#177
dependabot[bot] wants to merge 1 commit into
masterfrom
dependabot/npm_and_yarn/master/reselect-4.1.3

Conversation

@dependabot
Copy link
Copy Markdown

@dependabot dependabot Bot commented on behalf of github Nov 16, 2021

Bumps reselect from 3.0.1 to 4.1.3.

Release notes

Sourced from reselect's releases.

v4.1.3

This release rewrites the TS type inference of input selector parameters for correctness, fixes inference of createStructuredSelector inputs, and fixes an issue with the OutputSelectorFields type not being exported.

Changelog

Input Selector Parameter Inference Improvements

Reselect's types have always been extremely tricky, because it involves passing multiple input selectors with potentially heterogeneous, and then nested function composition of multiple selectors. Additionally, the input selectors can be passed as individual arguments or a single array of input selectors.

The 4.0.0 typedefs dealt with this by hand-writing dozens of overloads, which was absolutely impossible to maintain.

In 4.1, we took advantage of TS's improved abilities to infer array/tuple types to consolidate the typedefs.

One of the issues that happened as a result was that arguments at the same input parameter index were being "unioned" together, rather than "intersectioned". For example, in this complex selector:

  const input1 = (
    _: StateA,
    { testNumber }: { testNumber: number },
    c: number,
    d: string
  ) => testNumber
const input2 = (
_: StateA,
{ testString }: { testString: string },
c: number | string
) => testString
const input3 = (
_: StateA,
{ testBoolean }: { testBoolean: boolean },
c: number | string,
d: string
) => testBoolean
const input4 = (_: StateA, { testString2 }: { testString2: string }) =>
testString2
const testSelector = createSelector(
input1,
input2,
input3,
input4,
(testNumber, testString, testBoolean) => testNumber + testString
)

The second arg should end up as an object like {testNumber: number, testString: string, testBoolean: boolean, testString2: string}. However, it was ending up as four separate one-field objects. Similarly, the combination of number and number | string should be narrowed down to just number as an acceptable value.

... (truncated)

Commits
  • 9d899c1 4.1.3
  • 25d9b5f Merge pull request #549 from reduxjs/feature/improve-params-types
  • 6e23641 Try ignoring failures under TS 4.2/4.3
  • 10aa3c2 Export OutputSelectorFields type to fix breakages
  • f3628d7 Port Any.Compute expansion type from ts-toolbelt
  • eb78f3e Fix param inference for createStructuredSelector
  • 9576fa9 Simplify type display of output selectors (ie, clearCache)
  • e935a4b Rewrite selector parameter extraction for correctness
  • ef944e6 Fill in missing types in unit tests
  • a012109 Expand typetests with coverage for additional issues + code updates
  • Additional commits viewable in compare view
Maintainer changes

This version was pushed to npm by acemarke, a new releaser for reselect since your current version.


Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Bumps [reselect](https://github.com/reduxjs/reselect) from 3.0.1 to 4.1.3.
- [Release notes](https://github.com/reduxjs/reselect/releases)
- [Changelog](https://github.com/reduxjs/reselect/blob/master/CHANGELOG.md)
- [Commits](reduxjs/reselect@v3.0.1...v4.1.3)

---
updated-dependencies:
- dependency-name: reselect
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot Bot added the dependencies Pull requests that update a dependency file label Nov 16, 2021
@dependabot @github
Copy link
Copy Markdown
Author

dependabot Bot commented on behalf of github Nov 17, 2021

Superseded by #178.

@dependabot dependabot Bot closed this Nov 17, 2021
@dependabot dependabot Bot deleted the dependabot/npm_and_yarn/master/reselect-4.1.3 branch November 17, 2021 08:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants