Skip to content

Update Concurrent.js #43

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

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions src/React/Basic/DOM/Concurrent.js
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
import ReactDOM from "react-dom";
const createRoot = ReactDOM.createRoot || ReactDOM.unstable_createRoot;
const createBlockingRoot =
import ReactDOM from "react-dom/client";
const createRoot_ = ReactDOM.createRoot || ReactDOM.unstable_createRoot;
const createBlockingRoot_ =
ReactDOM.createBlockingRoot || ReactDOM.unstable_createBlockingRoot;

export function createRoot(element) {
return () => createRoot(element);
return () => createRoot_(element);
}

export function createBlockingRoot(element) {
return () => createBlockingRoot(element);
return () => createBlockingRoot_(element);
}

export function renderRoot(root) {
Expand Down
2 changes: 1 addition & 1 deletion src/React/Basic/DOM/Server.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
import ReactDOMServer from "react-dom/server.js";
import ReactDOMServer from "react-dom/server";
export var renderToString = ReactDOMServer.renderToString;
export var renderToStaticMarkup = ReactDOMServer.renderToStaticMarkup;