Accepted answer

It appears to be a common issue, and has been raised multiple times in the linked github issues section. There is no full code example that is provided, so posting my own solution here, just in case, another book reader is stumped like me.

  <form onSubmit={handleSubmit}>
      {...register("search")} defaultValue={criteria}
      placeholder="type here"

More details here -


Check that the package.json has:

"react-hook-form": "^6.12.2"

And when building:

npm install --legacy-peer-deps

Related Query

More Query from same tag