In development, frameworks like CRA, Next.js, etc. all include file metadata (e.g. fileName, lineNumber, columNumber) when transforming JSX. (Link babel plugin here)
On hover or right-click, click-to-react-component grabs the React renderer & finds the Fiber node associated with the DOM element (e.g. $0['__reactFiber$fq4qzh0im06'])
This fiber node has a __debugSource value that contains the file metadata from babel.
fileName
,lineNumber
,columNumber
) when transforming JSX. (Link babel plugin here)click-to-react-component
grabs the React renderer & finds the Fiber node associated with the DOM element (e.g.$0['__reactFiber$fq4qzh0im06']
)__debugSource
value that contains the file metadata from babel.