How the get the FiberNode in React Hook?

Viewed 350

I want to get the Fiber node in Hook,But don't know how to ?

import React from 'react';

export default function App() {
  // get the FiberNode in this Component
  return <div></div>;
}

1 Answers

I found the way, document.getElementById("root")._reactRootContainer._internalRoot.current

Related