Skip to content

Instantly share code, notes, and snippets.

@whisher
Last active April 25, 2023 17:55
Show Gist options
  • Save whisher/1e6822400451938fdc78ed926ef2f8d2 to your computer and use it in GitHub Desktop.
Save whisher/1e6822400451938fdc78ed926ef2f8d2 to your computer and use it in GitHub Desktop.
Ngrx ActionReducerMap example
import { ActionReducerMap } from '@ngrx/store';
import {
userAddressesReducer,
UserAddressesState
} from './user-addresses.reducer';
import { userProfileReducer, UserProfileState } from './user-profile.reducer';
export interface UserState {
addresses: UserAddressesState;
profile: UserProfileState;
}
export const userReducer: ActionReducerMap<UserState> = {
addresses: userAddressesReducer,
profile: userProfileReducer
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment