Preact-devtools icon highlights Preact sites only in dev mode
yassinebridi opened this issue · comments
I have noticed that the preact-devtools icon highlights Preact powered sites only in dev mode.
It would great to have it in production too, to quickly identify preact websites, like React devtools.
The icon will only light up in production when the user has signaled Preact to connect to the devtools extension. When don't have that enabled by default as some portion of our userbase prefers to have that turned of during production.
You can enable it during production by adding the preact/devtools
import as the top import in your app.
import { h, render } from "preact";
import "preact/devtools"; // <- insert this line
import App from "./App;
render(<App />, document.getElementById("app"));