Skip to content

Commit

Permalink
docs(redux): replace patchState with updateState
Browse files Browse the repository at this point in the history
  • Loading branch information
rainerhahnekamp committed Jan 28, 2025
1 parent cb3e30e commit f32b36a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions docs/docs/with-redux.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ export const FlightStore = signalStore(
},
reducer(actions, on) {
on(actions.loaded, ({ flights }, state) => {
patchState(state, 'flights loaded', { flights });
updateState(state, 'flights loaded', { flights });
});
},
effects(actions, create) {
Expand Down Expand Up @@ -82,11 +82,11 @@ const actions = {
// this can be in a separate file
const reducer = createReducer<FlightState, typeof actions>((actions, on) => {
on(actions.updateEffect1, (state, { value }) => {
patchState(state, { effect1: value });
updateState(state, 'update effect 1', { effect1: value });
});

on(actions.updateEffect2, (state, { value }) => {
patchState(state, { effect2: value });
updateState(state, 'update effect 2', { effect2: value });
});
});

Expand Down

0 comments on commit f32b36a

Please sign in to comment.