Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Typescript error with Control #3002

Closed
rusefendi opened this issue Sep 25, 2020 · 1 comment · Fixed by #3005
Closed

Typescript error with Control #3002

rusefendi opened this issue Sep 25, 2020 · 1 comment · Fixed by #3005
Labels
bug Something isn't working TS Typescript related issues

Comments

@rusefendi
Copy link

Describe the bug
Typescript error with Control type from example (https://react-hook-form.com/ts#Control)

To Reproduce

  1. Open https://codesandbox.io/s/objective-raman-jyt0g?file=/src/App.tsx
  2. Look at the control prop from IsolateReRender component.
  3. See error

Codesandbox link (Required)
https://codesandbox.io/s/objective-raman-jyt0g?file=/src/App.tsx

Expected behavior
Not having any errors

@bluebill1049 bluebill1049 added bug Something isn't working TS Typescript related issues labels Sep 25, 2020
@bluebill1049
Copy link
Member

bluebill1049 commented Sep 25, 2020

This issue is occurred at 6.8.5

possible related to this PR: #2899

bluebill1049 added a commit that referenced this issue Sep 26, 2020
* Revert "⌨️ refactor UseFormMethods to arrow functions (#2899)"

This reverts commit 3d713b3.

* attach useWatch type test

* include Control generic

* fix some minor type error

* fix readme
Tymek added a commit to Tymek/react-hook-form that referenced this issue Oct 13, 2020
vs. Typescript error with Control react-hook-form#3002
Tymek added a commit to Tymek/react-hook-form that referenced this issue Oct 13, 2020
vs. Typescript error with Control react-hook-form#3002
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 14, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working TS Typescript related issues
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants