Skip to content
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

constrain return type of slice selectors to members of State #231

Open
wflemingnz-retired opened this issue Mar 14, 2020 · 0 comments
Open

Comments

@wflemingnz-retired
Copy link

Was previously achieved using code below. This will ensure slice selectors do not perform any logic, which is important as they are not memoized.

export type SliceProjector = <TSlice extends keyof State>(
state: State
) => State[TSlice];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants