Skip to content

Re-export setGlobalDevModeChecks from reselect #4681

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

Closed
nodwyer4 opened this issue Oct 28, 2024 · 1 comment
Closed

Re-export setGlobalDevModeChecks from reselect #4681

nodwyer4 opened this issue Oct 28, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@nodwyer4
Copy link

nodwyer4 commented Oct 28, 2024

Hi, we'd love the ability to directly import setGlobalDevModeChecks from @reduxjs/toolkit rather than importing the values from reselect

We are importing it currently using this so that we can run our test files without the stability checks for performance reasons. We have these turned back on for our tests in CI

const { setGlobalDevModeChecks } = require(
    require.resolve("reselect", {
        paths: [require.resolve("@reduxjs/toolkit")],
    }),
);

Your current exports for re-select

export type { Selector, OutputSelector } from 'reselect'

Happy to raise a pr to change to this, as long as you are happy with the change

export type { Selector, OutputSelector, setGlobalDevModeChecks } from 'reselect'
@markerikson
Copy link
Collaborator

I don't think this is a thing I want us to explicitly re-export atm. The request is reasonable, but we've tried to avoid fully re-exporting everything from Reselect and Immer. Another example of this is createStructuredSelector. Yes it exists, and yes there's times you might want / need to use it, but we don't feel it's used often enough to justify explicitly making RTK depend on it. I feel like this falls into the same category. If you specifically need to change that setting, your current approach is the right way to do it - import it yourself directly from reselect.

@markerikson markerikson closed this as not planned Won't fix, can't repro, duplicate, stale Apr 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants