Skip to content
PluginStats

vite-string-plugin weekly downloads statistics

By silverwind (2 listings) · npm · Vite plugins

Vite plugin to import files as string

View on npm Fresh · Dec 6, 2026

vite-string-plugin has 16,570 recorded weekly downloads on npm, an increase of 71.0% over the past 30 days, ranking #1102 of 3,247 tracked listings.

Weekly downloads
16,570
Official API · Dec 5, 2026
7-day growth
+4.5%
+708 weekly downloads
30-day growth
+71.0%
+6.9K weekly downloads
90-day growth
+128%
+9.3K weekly downloads
Rank
#1102
▲ 2 in 7 days

About vite-string-plugin

vite-string-plugin

Vite plugin to import files as string, with zero dependencies

Usage

pnpm add -D vite-string-plugin

In vite.config.ts:

import {defineConfig} from "vite";
import {stringPlugin} from "vite-string-plugin";

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

In your code:

import foo from "./foo.svg";

Options

  • match: Regex to match the path against. Default: /\.(svg|md|xml|txt)$/i.

TypeScript

vite-string-plugin/types declares modules for the svg, md, txt and pdf extensions. If those cover your needs, add it to your types in tsconfig.json:

{
  "compilerOptions": {
    "types": [
      "vite-string-plugin/types"
    ]
  }
}

Alternatively, you can add ambient type declarations for each file extension:

declare module "*.svg" {
  const value: string;
  export default value;
}
declare module "*.md" {
  const value: string;
  export default value;
}
declare module "*.xml" {
  const value: string;
  export default value;
}
declare module "*.txt" {
  const value: string;
  export default value;
}

Related

© silverwind, distributed under BSD licence

Description from the npm listing.

  • vite
  • vite-plugin
  • string
  • raw
  • import
  • loader

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-string-plugin weekly downloads on npm, last 90 days: 16,570 weekly downloads as of Dec 5, 2026, +128% over 90 days.vite-string-pluginWeekly downloads on npm · Last 90 days16,570downloads / week+128% over 90 days02K4K6K8K10K12K14K16K18KSep 6Sep 21Oct 6Oct 21Nov 5Nov 20Dec 5downloads / weekobservedarchived (Internet Archive)no observationsSep 7, 2026 – Dec 5, 2026 · 90 observations · Updated Dec …pluginstats.com
vite-string-plugin weekly downloads on npm, last 90 days: 16,570 weekly downloads as of Dec 5, 2026, +128% over 90 days.

7/30/90-day growth

vite-string-plugin weekly downloads growth on npm: +4.5% over 7 days, +71.0% over 30 days, +128% over 90 days.vite-string-pluginWeekly downloads growth on npm16,570downloads / week now7-day growth+708 weekly downloads+4.5%30-day growth+6,880 weekly downloads+71.0%90-day growth+9,302 weekly downloads+128%Growth vs. nearest observation to each baseline date · Updated Dec 5, 2026pluginstats.com
vite-string-plugin weekly downloads growth on npm: +4.5% over 7 days, +71.0% over 30 days, +128% over 90 days.

Ranking history

vite-string-plugin npm ranking history: currently #1102 (by weekly downloads).vite-string-pluginnpm ranking · by weekly downloads · Last 90 days#1102current rank#1000#1050#1100#1150#1200#1250Sep 7Sep 22Oct 7Oct 22Nov 6Nov 21Dec 6rankOct 18, 2026 – Dec 6, 2026 · 44 observations · Updated Dec 5, 2026pluginstats.com
vite-string-plugin npm ranking history: currently #1102 (by weekly downloads).

Listing placement

All npm3,247 listings · 163 pages · 1,083 shown · page 56, #2 (overall #1,102)
All npm: every listing in weekly downloads order

Listing placement

Vite plugins300 listings · 15 pages · page 10, #9 (overall #189)
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 (170)
Recent weekly downloads observations for vite-string-plugin
Date (UTC)Weekly downloadsChange vs. previous
16,570+724
15,846+1.2K
14,682+460
14,222+282
13,940-1.2K
15,157+357
14,800-1.1K
15,862-485
16,347-920
17,267+271
16,996-430
17,426+1K
16,412-792
17,204—

Similar npm Vite plugins plugins

All 20 vite-string-plugin 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-string-plugin. First seen Oct 16, 2026; last successful collection Dec 6, 2026. See the methodology.