Skip to content

Commit

Permalink
Revert "Rename internal fields (#18377)"
Browse files Browse the repository at this point in the history
This reverts commit 2ba43ed.
  • Loading branch information
gaearon authored Mar 25, 2020
1 parent 6498f62 commit cbae955
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions packages/react-dom/src/client/ReactDOMComponentTree.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,10 @@ import {getParentSuspenseInstance} from './ReactDOMHostConfig';
const randomKey = Math.random()
.toString(36)
.slice(2);
const internalInstanceKey = '__reactFiber$' + randomKey;
const internalEventHandlersKey = '__reactEvents$' + randomKey;
const internalContainerInstanceKey = '__reactContainer$' + randomKey;
const internalEventListenersKey = '__reactListeners$' + randomKey;
const internalInstanceKey = '__reactInternalInstance$' + randomKey;
const internalEventHandlersKey = '__reactEventHandlers$' + randomKey;
const internalContainerInstanceKey = '__reactContainere$' + randomKey;
const internalEventListenersKey = '__reactEventListeners$' + randomKey;

export function precacheFiberNode(
hostInst: Fiber,
Expand Down
8 changes: 4 additions & 4 deletions packages/shared/ReactInstanceMap.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,17 +21,17 @@
* supported we can rename it.
*/
export function remove(key) {
key._reactInternals = undefined;
key._reactInternalFiber = undefined;
}

export function get(key) {
return key._reactInternals;
return key._reactInternalFiber;
}

export function has(key) {
return key._reactInternals !== undefined;
return key._reactInternalFiber !== undefined;
}

export function set(key, value) {
key._reactInternals = value;
key._reactInternalFiber = value;
}

0 comments on commit cbae955

Please sign in to comment.