Bug: div: ref
is not a prop
#30367
Labels
Status: Unconfirmed
A potential issue that we haven't yet confirmed as a bug
ref
is not a prop
#30367
Using Vite & React we're getting the weirdest error i've seen in all my react career:
I'm clueless, how does react warn me that
ref
is not a prop for<div>
?Accompanied is a whole bunch of other errors related to contexts:
React version:
18.3.1
Steps To Reproduce
We tried to reproduce it but it does not happen in a minimal example.
Please advice on tactics/methods to write a minimal reproducible to try and get this error.
The component giving this error is rendering a
createPortal
to thedocument.body
:Large Node Tree With recursively rendered components and form elements just to show it's a complex application which I think is what contributes to why we can't replicated it.
Link to code example: WIP
The current behavior
VM18671:1 Warning: div:
ref
is not a prop. Trying to access it will result inundefined
being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)The expected behavior
No Error
The text was updated successfully, but these errors were encountered: