Repository navigation
v0.3.0
The new deadhead/vite export adds dev-time checking to Vite 8 projects. Both
published packages move to 0.3.0 together. The rule set is unchanged: 203 rules,
with the same findings and autofixes as 0.2.1.
Vite integration
- Add
deadhead()fromdeadhead/viteto your Vite config to report findings,
advice and rule links in the terminal and DevTools console during development
(#502). - Checks use the CLI parser and inspect completed HTML responses, including SSR
streams served through Vite's middleware stack. Positions refer to the served
HTML. Frameworks with a separate HTML server need the CLI or bookmarklet. - Read rule settings and URL filters from
deadhead.config.tsin Vite's root,
with plugin options overriding the file. Setconsole: falsefor terminal
reports with unchanged response bytes and headers. - The plugin checks UTF-8 HTML up to 2 MiB, preserves streamed writes and
backpressure, and skips compressed or partial responses. It respects
Cache-Control: no-transformand uses Vite's configured CSP nonce for console
output. A blocked console script leaves the terminal report available. - Vite is an optional peer; CLI users do not install it. The plugin ships
JavaScript and TypeScript declarations. Builds keep using
"postbuild": "deadhead dist"after the framework writes its final output.
Bookmarklet
- The full report button re-reads the page's HTML in your browser and opens it on
/try, with positions, advice and fixed HTML. If CSP blocks the re-read, it
sends the rendered DOM. The HTML travels in the URL fragment;/tryclears it
after reading it (#501).