vite-plugin-sri-gen
JSON →A Vite plugin that auto-generates Subresource Integrity (SRI) hashes for built assets and injects integrity/crossorigin attributes into HTML output. Current stable version 1.4.1, requires Node ≥18 and Vite ≥4. Released monthly. Key differentiators: supports multiple hash algorithms (sha256, sha384, sha512), optional lazy-loaded chunk integrity via runtime patch, Vite manifest augmentation for SSR/backend-owned HTML, configurable include/exclude patterns, and in-memory HTTP cache. ESM-only, builds on parse5 for HTML parsing. Does not work for most SSR frameworks unless pre-rendering HTML or reading the augmented manifest.
Traffic · last 30 days ↓67% vs prev 7d
total hits 10
actors 3 distinct systems
last hit 1d ago AhrefsBot
top countries 🇺🇸 United States · 🇬🇧 United Kingdom · 🇨🇦 Canada
Resources
API endpoints
full doc /v1/registry/vite-plugin-sri-gen