FormLayout with react-hook-form
Posted: 10 Jul 2020, 21:11
I am currently using react-hook-form and hooks react-redux to manage input and state.
I have=ing an issue getting components such InputText when enclosed in a <form onSubmit={handleSubmit(onSubmitForm)}> tag to show as red or display an error message when I use the error property.
Using semantic-ui-react these integrate, but I would like to migrate over to PrimeReact but this is a blocker
The issue appears to be caused by PrimeReact not exposing ref. https://github.com/react-hook-form/reac ... /issues/51
Can a change be made to allow PrimeReact to work with react-hook-form?
Thank you.
I have=ing an issue getting components such InputText when enclosed in a <form onSubmit={handleSubmit(onSubmitForm)}> tag to show as red or display an error message when I use the error property.
Code: Select all
<InputText
id="logonName"
name="logonName"
type="text"
onChange={onNameChange}
errors={
errors.logonName
? {
content: errors.logonName.message,
pointing: "below",
}
: false
}
/>
Using semantic-ui-react these integrate, but I would like to migrate over to PrimeReact but this is a blocker
The issue appears to be caused by PrimeReact not exposing ref. https://github.com/react-hook-form/reac ... /issues/51
Can a change be made to allow PrimeReact to work with react-hook-form?
Thank you.