export function createAction < T extends string > ( type ) ; export function createAction < T extends string , P extends any > ( type , payload ) ; export function createAction ( type , payload ? ) { return { type , payload } ; }