Skip to content
PluginStats

vite-plugin-sri-gen weekly downloads statistics

By rbonestell · npm · Vite plugins

A Vite plugin to auto-generate Subresource Integrity (SRI) hashes.

View on npm Fresh · Oct 18, 2026

vite-plugin-sri-gen has 5,173 recorded weekly downloads on npm, a decrease of 28.9% over the past 30 days, ranking #1132 of 2,322 tracked listings.

Weekly downloads
5,173
Official API · Oct 18, 2026
7-day growth
-62.7%
-8.7K weekly downloads
30-day growth
-28.9%
-2.1K weekly downloads
90-day growth
-42.8%
-3.9K weekly downloads
Rank
#1132
Among tracked npm listings

About vite-plugin-sri-gen

<p align="center"> <img src="https://repository-images.githubusercontent.com/1034544632/2b674281-ff9c-4510-a0ef-91c33e395f0b" width=60% height=60% alt="vite-plugin-sri-gen" /> </p> <p align="center"> Add <a href="https://developer.mozilla.org/en-US/docs/Web/Security/Subresource_Integrity">Subresource Integrity (SRI)</a> hashes to your Vite build HTML output automatically. </p> <p align="center"> <a href="https://www.npmjs.com/package/vite-plugin-sri-gen"><img src="https://img.shields.io/npm/v/vite-plugin-sri-gen.svg" alt="NPM Version"></a> <a href="https://github.com/rbonestell/vite-plugin-sri-gen/actions/workflows/build.yml?query=branch%3Amain"><img src="https://img.shields.io/github/actions/workflow/status/rbonestell/vite-plugin-sri-gen/build.yml?logo=typescript&logoColor=white" alt="Build Status"></a> <a href="https://github.com/rbonestell/vite-plugin-sri-gen/actions/workflows/test.yml?query=branch%3Amain"><img src="https://img.shields.io/github/actions/workflow/status/rbonestell/vite-plugin-sri-gen/test.yml?branch=main&logo=vite&logoColor=white&label=tests" alt="Test Results"></a> <a href="https://app.codecov.io/gh/rbonestell/vite-plugin-sri-gen/"><img src="https://img.shields.io/codecov/c/github/rbonestell/vite-plugin-sri-gen?logo=codecov&logoColor=white" alt="Code Coverage"></a> <a href="https://snyk.io/test/github/rbonestell/vite-plugin-sri-gen"><img src="https://img.shields.io/badge/security-monitored-8A2BE2?logo=snyk" alt="Known Vulnerabilities"></a> <a href="https://socket.dev/npm/package/vite-plugin-sri-gen"><img src="https://badge.socket.dev/npm/package/vite-plugin-sri-gen" alt="Known Vulnerabilities"></a> <a href="LICENSE"><img src="https://img.shields.io/badge/license-MIT-3DA639?logo=opensourceinitiative&logoColor=white" alt="License"></a> </p>

vite-plugin-sri-gen

Add Subresource Integrity (SRI) hashes to your Vite build automatically.

  • Adds integrity to scripts, stylesheets, and modulepreload links in emitted HTML — plus import map integrity, modulepreload injection for lazy chunks, a CSP-safe runtime for dynamic tags, and Vite manifest augmentation for backend-rendered HTML
  • Build-only by design — works out of the box for SPA, MPA, and prerendered SSG output
  • ESM-only, Node 18+, Vite 4+

Documentation

📚 Full documentation →

Install

npm i -D vite-plugin-sri-gen

Quick start

// vite.config.ts
import sri from "vite-plugin-sri-gen";

export default {
  plugins: [sri()],
};

That's it — every build gets SRI with sensible defaults. See the configuration reference for algorithm, crossorigin, skip patterns, and more.

[!IMPORTANT] Pure SSR output (HTML rendered at request time) cannot be modified at build time. Prerendered HTML works normally, and backends that render their own HTML can consume SRI hashes from the augmented Vite manifest. Details: SSR, SSG & Prerendering.

Contributing

Contributions are welcome. Please read CONTRIBUTING.md for the fork/branch/PR workflow and the testing/linting expectations.

Security

See SECURITY.md for supported versions and how to report vulnerabilities.

License

MIT — see LICENSE.

Description from the npm listing.

  • vite
  • subresource
  • integrity
  • sri
  • content
  • security
  • policy
  • csp
  • plugin
  • vite-plugin
  • vite-plugin-sri
  • vite-sri
  • subresource-integrity
  • integrity-hash
  • sha256
  • sha384
  • sha512
  • modulepreload
  • ssr
  • ssg

README badge

Show your rank in a README or on your website. The badge updates automatically.

Charts

Images: 30d · 1y · all time · 1600×900 dark

Adoption over time

vite-plugin-sri-gen weekly downloads on npm, last 90 days: 5,173 weekly downloads as of Oct 18, 2026, -42.8% over 90 days.vite-plugin-sri-genWeekly downloads on npm · Last 90 days5,173downloads / week-42.8% over 90 days02K4K6K8K10K12K14K16K18KJul 20Aug 4Aug 19Sep 3Sep 18Oct 3Oct 18downloads / weekobservedarchived (Internet Archive)no observationsJul 22, 2026 – Oct 18, 2026 · 89 observations · Updated Oc…pluginstats.com
vite-plugin-sri-gen weekly downloads on npm, last 90 days: 5,173 weekly downloads as of Oct 18, 2026, -42.8% over 90 days.

7/30/90-day growth

vite-plugin-sri-gen weekly downloads growth on npm: -62.7% over 7 days, -28.9% over 30 days, -42.8% over 90 days.vite-plugin-sri-genWeekly downloads growth on npm5,173downloads / week now7-day growth-8,709 weekly downloads-62.7%30-day growth-2,101 weekly downloads-28.9%90-day growth-3,877 weekly downloads-42.8%Growth vs. nearest observation to each baseline date · Updated Oct 18, 2026pluginstats.com
vite-plugin-sri-gen weekly downloads growth on npm: -62.7% over 7 days, -28.9% over 30 days, -42.8% over 90 days.

Ranking history

vite-plugin-sri-gen npm ranking history: currently #1132 (by weekly downloads).vite-plugin-sri-gennpm ranking · by weekly downloads · Last 90 days#1132current rank#1100#1105#1110#1115#1120#1125#1130#1135Jul 22Aug 6Aug 21Sep 5Sep 20Oct 5Oct 20rankOct 18, 2026 – Oct 20, 2026 · 3 observations · Updated Oct 18, 2026pluginstats.com
vite-plugin-sri-gen npm ranking history: currently #1132 (by weekly downloads).

Listing placement

All npm2,320 listings · 116 pages · 1,161 shown · page 57, #15 (overall #1,135)
All npm: every listing in weekly downloads order

Listing placement

Vite plugins253 listings · 13 pages · page 11, #7 (overall #207)
Vite plugins: every listing in weekly downloads order

Filled points are observed values; hollow points come from Internet Archive snapshots of the listing page. Dashed segments span periods with no observations — values between points are not interpolated.

Each band is one page of 20. Weekly downloads on a linear scale. Placement is projected from weekly downloads, so it can differ from the marketplace's own sort order. Hover a dot to see the listing.

Recent observations

Full history (122)
Recent weekly downloads observations for vite-plugin-sri-gen
Date (UTC)Weekly downloadsChange vs. previous
5,173+499
4,674-1.3K
5,925-231
6,156-2.9K
9,031-3.7K
12,7800
12,780-1.1K
13,882-347
14,229+373
13,856-384
14,240-474
14,714+1.1K
13,571-2.7K
16,242—

Similar npm Vite plugins plugins

All 20 vite-plugin-sri-gen alternatives

Data source

Weekly downloads (trailing 7 complete days) come from the official npm downloads API. Downloads include CI and mirrors and are not equivalent to installs or users. npm publishes no ratings.

Listing: https://www.npmjs.com/package/vite-plugin-sri-gen. First seen Oct 16, 2026; last successful collection Oct 20, 2026. See the methodology.