export function createActionPayload<TypeAction, TypePayload>( actionType: TypeAction): (payload: TypePayload) => ActionsWithPayload<TypeAction, TypePayload> {
return (p: TypePayload): ActionsWithPayload<TypeAction, TypePayload> => {
return {
payload: p,
type: actionType
};
};
}
这是发送动作的功能