Skip to content

Commit ea35c40

Browse files
committed
deleted commments
1 parent 165aa6b commit ea35c40

File tree

1 file changed

+1
-32
lines changed

1 file changed

+1
-32
lines changed

src/backend/linkFiber.ts

Lines changed: 1 addition & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -60,13 +60,8 @@ const circularComponentTable = new Set();
6060
let allAtomsRelationship = [];
6161

6262
function getRecoilState() : any {
63-
// get the last state snapshot
6463
const RecoilSnapshotsLength = window[`$recoilDebugStates`].length;
6564
const lastRecoilSnapshot = window[`$recoilDebugStates`][RecoilSnapshotsLength - 1];
66-
console.log(lastRecoilSnapshot);
67-
68-
// get all atom - selector pairs, and save them as nodes
69-
// in the from to weight format
7065
const nodeToNodeSubs = lastRecoilSnapshot.nodeToNodeSubscriptions;
7166
let nodeToNodeSubsKeys = lastRecoilSnapshot.nodeToNodeSubscriptions.keys();
7267
nodeToNodeSubsKeys.forEach(
@@ -76,21 +71,6 @@ function getRecoilState() : any {
7671
)
7772
}
7873
)
79-
80-
// get all atom - component pairs, and save them as nodes
81-
// in the from to weight format
82-
83-
// const nodeToCompSubs = lastRecoilSnapshot.nodeToComponentSubscriptions;
84-
// console.log(nodeToCompSubs);
85-
// let nodeToCompSubsKeys = lastRecoilSnapshot.nodeToComponentSubscriptions.keys();
86-
// nodeToCompSubsKeys.forEach(
87-
// node => {
88-
// console.log(node);
89-
// // nodeToCompSubsKeys.get(node).forEach(
90-
// // nodeSubs => allAtomsRelationship.push([node, nodeSubs, 2])
91-
// // )
92-
// }
93-
// )
9474
}
9575

9676

@@ -399,18 +379,7 @@ export default (snap: Snapshot, mode: Mode): (() => void) => {
399379
}
400380

401381
return () => {
402-
/* const container = document.getElementById('root');
403-
if (container._internalRoot) {
404-
fiberRoot = container._internalRoot;
405-
} else {
406-
const {
407-
_reactRootContainer: { _internalRoot },
408-
_reactRootContainer,
409-
} = container;
410-
// Only assign internal root if it actually exists
411-
fiberRoot = _internalRoot || _reactRootContainer;
412-
}
413-
*/
382+
414383
const devTools = window.__REACT_DEVTOOLS_GLOBAL_HOOK__;
415384
const reactInstance = devTools ? devTools.renderers.get(1) : null;
416385
fiberRoot = devTools.getFiberRoots(1).values().next().value;

0 commit comments

Comments
 (0)