Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
Prev Previous commit
Next Next commit
Run Prettier
  • Loading branch information
trueadm committed Sep 26, 2018
commit 5d6d348e0d286cbe460f104095e847df4860e4ca
6 changes: 5 additions & 1 deletion packages/react-dom/src/client/ReactDOM.js
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,11 @@ ReactWork.prototype._onCommit = function(): void {
}
};

function ReactRoot(container: Container, isConcurrent: boolean, hydrate: boolean) {
function ReactRoot(
container: Container,
isConcurrent: boolean,
hydrate: boolean,
) {
const root = DOMRenderer.createContainer(container, isConcurrent, hydrate);
this._internalRoot = root;
}
Expand Down
10 changes: 8 additions & 2 deletions packages/react-noop-renderer/src/createReactNoop.js
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,10 @@ function createReactNoop(reconciler: Function, useMutation: boolean) {
renderLegacySyncRoot(element: React$Element<any>, callback: ?Function) {
const rootID = DEFAULT_ROOT_ID;
const isConcurrent = false;
const container = ReactNoop.getOrCreateRootContainer(rootID, isConcurrent);
const container = ReactNoop.getOrCreateRootContainer(
rootID,
isConcurrent,
);
const root = roots.get(container.rootID);
NoopRenderer.updateContainer(element, root, null, callback);
},
Expand All @@ -490,7 +493,10 @@ function createReactNoop(reconciler: Function, useMutation: boolean) {
callback: ?Function,
) {
const isConcurrent = true;
const container = ReactNoop.getOrCreateRootContainer(rootID, isConcurrent);
const container = ReactNoop.getOrCreateRootContainer(
rootID,
isConcurrent,
);
const root = roots.get(container.rootID);
NoopRenderer.updateContainer(element, root, null, callback);
},
Expand Down