14 lines
291 B
TypeScript
14 lines
291 B
TypeScript
|
import { createReducer, on } from '@ngrx/store';
|
||
|
import { initialState } from './state';
|
||
|
import { authSuccess } from './actions';
|
||
|
|
||
|
export const reducer = createReducer(
|
||
|
initialState,
|
||
|
on(authSuccess, (state, action) => {
|
||
|
return {
|
||
|
...state,
|
||
|
auth: action.res
|
||
|
};
|
||
|
})
|
||
|
);
|