mirror of
https://github.com/muerwre/vault-frontend.git
synced 2025-04-26 05:16:41 +07:00
11 lines
366 B
TypeScript
11 lines
366 B
TypeScript
import assocPath from 'ramda/es/assocPath';
|
|
import { FLOW_ACTIONS } from './constants';
|
|
import { flowSetNodes } from './actions';
|
|
import { IFlowState } from './reducer';
|
|
|
|
const setNodes = (state: IFlowState, { nodes }: ReturnType<typeof flowSetNodes>) =>
|
|
assocPath(['nodes'], nodes, state);
|
|
|
|
export const FLOW_HANDLERS = {
|
|
[FLOW_ACTIONS.SET_NODES]: setNodes,
|
|
};
|