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

Add setOne and setMany to entity adapter #969

Merged

Conversation

HHK1
Copy link
Contributor

@HHK1 HHK1 commented Mar 31, 2021

Fixes #954

upsertOne and upsertMany merge the passed value with the existing item,
but there was no direct way to replace items.
setOne and setMany solve this and replace entirely the previous value
with the new one.

upsertOne and upsertMany merge the passed value with the existing item,
but there was no direct way to replace items.
setOne and setMany solve this and replace entirely the previous value
with the new one.
@netlify
Copy link

netlify bot commented Mar 31, 2021

Deploy preview for redux-starter-kit-docs ready!

Built with commit 67bd0b0

https://deploy-preview-969--redux-starter-kit-docs.netlify.app

@codesandbox-ci
Copy link

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 67bd0b0:

Sandbox Source
Vanilla Configuration
Vanilla Typescript Configuration
rsk-github-issues-example Configuration

@markerikson
Copy link
Collaborator

Very nice, and that's a comprehensive set of tests :) Thanks!

@markerikson markerikson merged commit 795af40 into reduxjs:master Apr 1, 2021
@HHK1 HHK1 deleted the add-setOne-setMany-to-entity-adapter branch April 1, 2021 07:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add setOne/setMany CRUD APIs to createEntityAdapter
2 participants