mirror of
https://github.com/facebook/react.git
synced 2025-11-01 09:12:30 +00:00
Change string refs in function component message (#18031)
This should refer to string refs specifically. The forwardRef part doesn't make any sense in this case. I think this was just an oversight.
This commit is contained in:
@@ -307,7 +307,7 @@
|
||||
"306": "Element type is invalid. Received a promise that resolves to: %s. Lazy element type must resolve to a class or function.%s",
|
||||
"307": "Hooks can only be called inside the body of a function component. (https://fb.me/react-invalid-hook-call)",
|
||||
"308": "Context can only be read while React is rendering. In classes, you can read it in the render method or getDerivedStateFromProps. In function components, you can read it directly in the function body, but not inside Hooks like useReducer() or useMemo().",
|
||||
"309": "Function components cannot have refs. Did you mean to use React.forwardRef()?",
|
||||
"309": "Function components cannot have string refs. We recommend using useRef() instead. Learn more about using refs safely here: https://fb.me/react-strict-mode-string-ref",
|
||||
"310": "Rendered more hooks than during the previous render.",
|
||||
"311": "Should have a queue. This is likely a bug in React. Please file an issue.",
|
||||
"312": "Rendered more hooks than during the previous render",
|
||||
|
||||
Reference in New Issue
Block a user