How to write a hook without consistent-components-exports warning #238
-
There are warnings everywhere, I try to fix them But I failed with hook,
with above code, there are warnings:
Could anyone give me some hint? |
Beta Was this translation helpful? Give feedback.
Answered by
ArnaudBarre
Oct 16, 2023
Replies: 1 comment 3 replies
-
Finally, I found change
to
But it is wired, we usually named a hook start with useXXX. |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Yeah
.ts
should work.I need to better understand how Fast refresh works for files with just custom hooks to maybe improve HMR for this kind of files