Closed as not planned
Description
Named hooks is currently only enabled for DevTools browser extensions. This is because the source map parsing library ('source-map'
) requires a WASM bundle to be supplied at runtime, and DevTools currently loads that using a browser API (chrome.extension.getURL
):
react/packages/react-devtools-extensions/src/parseHookNames/index.js
Lines 20 to 21 in 9f88b53
Maybe we could refactor this so that non-browser targets copied the WASM from node_modules
and bundled it along with the DevTools package? It would be nice to support this functionality for e.g. React Native (which uses react-devtools-core
) and Code Sandbox (which uses react-devtools-inline
).