Is there a way to pass formik form values from a child component to a parent component and handle form submission in parent component only. I have a use case where I'm building a form for restaurant. The form will have many many fields. So I grou...
Is there a yup function that validates a specific length?   I tried .min(5) and .max(5), but I want something that ensures the number is exactly 5 characters (ie, zip code)....
I'm using Yup to validate a signup form but I'm struggling to validate the credit card fields due to needing methods from both Yup's string and number schema.  Card number for example should not exceed 16 characters. This is easily achiev...
I'm trying to use Yup along with Formik in my react form. The form fields are going to be dynamic so as their validations.   export const formData = [   {     id: "name",     label: "Full name",     placeholder: "Enter full na...
I need to make a form validation using Yup to check input type email1, email2, email3, email4 and email5 in my React App.  The rule of thumb is easy. Check those emails is in valid form and cannot have similar emails values.   I am super new to Yup....
I have nested fields with number inputs and can't get the validation to work properly. Not sure if this is a problem with formik or yup / how the validation schema is declared but I'll start asking here.  In the example I have two fields whic...
Trying to validate a phone number field in Formik using Yup validation schema, but when i use Yup.string().matches(/^[0-9]*$/g, 'This is not a number') it consistently alternates between valid and invalid on each change event.      phone: Yup...
A question regarding type construction from data structures. I have an array like this:  interface ICVSection {   namespace: string;   validation: Yup.ObjectSchema<any>; }  const CVSections: ICVSection[] = [   {     namespace: 'common',...
For Example, Bank account number cannot have special characters and I would like to validate the user input using Yup and show error in case of special characters like @,#,$ etc and emoji's.  Main intention here is to know the use of regex with Y...
I've got a form with some text inputs, and some custom components. I've got the Formik validation working on the text inputs but not the custom components. I am now trying to add Formik validation to my custom categoriesMultiselect component....

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.