mirror of
https://github.com/hanzoai/react.git
synced 2026-09-24 17:02:27 +00:00
[DOM] disable legacy mode behind flag (#28468)
Adds a flag to disable legacy mode. Currently this flag is used to cause legacy mode apis like render and hydrate to throw. This change also removes render, hydrate, unmountComponentAtNode, and unstable_renderSubtreeIntoContainer from the experiemntal entrypoint. Right now for Meta builds this flag is off (legacy mode is still supported). In OSS builds this flag matches __NEXT_MAJOR__ which means it currently is on in experiemental. This means that after merging legacy mode is effectively removed from experimental builds. While this is a breaking change, experimental builds are not stable and users can pin to older versions or update their use of react-dom to no longer use legacy mode APIs.
This commit is contained in:
@@ -493,5 +493,6 @@
|
||||
"505": "Cannot render an Async Component, Promise or React.Lazy inside React.Children. We recommend not iterating over children and just rendering them plain.",
|
||||
"506": "Functions are not valid as a child of Client Components. This may happen if you return %s instead of <%s /> from render. Or maybe you meant to call this function rather than return it.%s",
|
||||
"507": "Expected the last optional `callback` argument to be a function. Instead received: %s.",
|
||||
"508": "The first argument must be a React class instance. Instead received: %s."
|
||||
"508": "The first argument must be a React class instance. Instead received: %s.",
|
||||
"509": "ReactDOM: Unsupported Legacy Mode API."
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user