import * as Yup from 'yup' ; import { ISignInFormValues } from './types' ; export const initialValues = { email : '' , password : '' } ; export const getValidationSchema = ( ) => Yup . object ( ) . shape ( { email : Yup . string ( ) . required ( 'email is required' ) , } ) ; export const isError = ( id ) => ( touched , errors ) => Boolean ( touched [ id ] && errors [ id ] ) ; export const isEmailError = isError ( 'email' ) ;