devtools
devtools copied to clipboard
Support builds without index.html
Clear and concise description of the problem
We have a micro-frontend architecture, and our newest MFE is using Vite 8.
For HMR, we have this in our entry file, which works well. It would be great to have a similar option for the DevTools.
import "@vitejs/plugin-react/preamble";
Suggested solution
Add a preamble for DevTools.
import "@vitejs/devtools/preamble";
Alternative
No response
Additional context
I'm not sure how this would work across multiple MFEs, or if that's on your roadmap.
Validations
- [x] Follow our Code of Conduct
- [x] Read the Contributing Guide.
- [x] Check that there isn't already an issue that request the same feature to avoid creating a duplicate.
It seems that we currently support it. I have updated it in the document. Try using import '@vitejs/devtools/client/inject' to explicitly import the DevTools client.
Sorry for the slow reply, that does work - thanks!