Skip to content

Commit 7c049fd

Browse files
committed
remove references to map from the docs
1 parent 9bb035e commit 7c049fd

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

docs/api/createEntityAdapter.md

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -118,8 +118,6 @@ export interface Dictionary<T> extends DictionaryNum<T> {
118118

119119
export type Update<T> = { id: EntityId; changes: Partial<T> }
120120

121-
export type EntityMap<T> = (entity: T) => T
122-
123121
export interface EntityState<T> {
124122
ids: EntityId[]
125123
entities: Dictionary<T>
@@ -171,9 +169,6 @@ export interface EntityStateAdapter<T> {
171169
state: S,
172170
entities: PayloadAction<T[]>
173171
): S
174-
175-
map<S extends EntityState<T>>(state: S, map: EntityMap<T>): S
176-
map<S extends EntityState<T>>(state: S, map: PayloadAction<EntityMap<T>>): S
177172
}
178173

179174
export interface EntitySelectors<T, V> {
@@ -208,7 +203,6 @@ The primary content of an entity adapter is a set of generated reducer functions
208203
- `updateMany`: accepts an array of update objects, and updates all corresponding entities
209204
- `upsertOne`: accepts a single entity. If an entity with that ID exists, the fields in the update will be merged into the existing entity, with any matching fields overwriting the existing values. If the entity does not exist, it will be added.
210205
- `upsertMany`: accepts an array of entities that will be upserted.
211-
- `map`: accepts a callback function that will be run against each existing entity, and may return a change description object. Afterwards, all changes will be merged into the corresponding existing entities.
212206

213207
Each method has a signature that looks like:
214208

0 commit comments

Comments
 (0)