Ever wonder why a particular website is showing a development build icon for React DevTools? Here's how you can find out!
First copy/paste this well-annotated DevTools build-type-checker function into your browser console so you can run it.
Next, execute the following line in your developer console:
console.log(__REACT_DEVTOOLS_GLOBAL_HOOK__._renderers);
If React is present on the page, you'll see something like:
{5b853225462e5: {…}}
Finally, pass the React renderer to the function we copy-pasted earlier and step through it to see why the development icon is being displayed:
debugger;
detectReactBuildType(__REACT_DEVTOOLS_GLOBAL_HOOK__._renderers['5b853225462e5']);