import { EmailAndPasswordPayload } from '../types' ; import { fetchSignInMethods , signIn as signInFunc , signUp as signUpFunc , } from './functions' ; import { CHECK_EMAIL , SIGN_IN , SIGN_UP } from './types' ; export const signIn = ( payload ) => ( dispatch ) => { dispatch ( { type : SIGN_IN , payload , firebase : signInFunc , } ) ; } ; export const signUp = ( payload ) => ( dispatch ) => { dispatch ( { type : SIGN_UP , payload , firebase : signUpFunc , } ) ; } ; export const checkEmail = ( payload ) => ( dispatch ) => { dispatch ( { type : CHECK_EMAIL , payload , firebase : fetchSignInMethods , } ) ; } ;