Skip to content
PluginStats

@stylexswc/webpack-plugin weekly downloads statistics

By stylexswc · npm · Webpack plugins

StyleX plugin for webpack powered by a Rust NAPI-RS/SWC compiler. Fast StyleX transforms and CSS extraction without Babel.

View on npm Fresh · Dec 6, 2026

@stylexswc/webpack-plugin has 41,983 recorded weekly downloads on npm, an increase of 38.4% over the past 30 days, ranking #835 of 3,247 tracked listings.

Weekly downloads
41,983
Official API · Dec 5, 2026
7-day growth
+38.3%
+11.6K weekly downloads
30-day growth
+38.4%
+11.7K weekly downloads
90-day growth
+196%
+27.8K weekly downloads
Rank
#835
▲ 59 in 7 days

About @stylexswc/webpack-plugin

@stylexswc/webpack-plugin

StyleX plugin for webpack, powered by a Rust compiler (NAPI-RS + SWC). Part of the StyleX SWC Plugin workspace.

This plugin compiles StyleX code in your webpack build with @stylexswc/rs-compiler, a Rust implementation of the StyleX transform, instead of the official Babel plugin. Your StyleX code stays exactly the same — only the build step changes, with per-file transforms 5x to 10x faster than Babel (performance). The plugin transforms your source files, collects the generated rules, and extracts them into a dedicated CSS chunk.

This is a community project and is not affiliated with Meta. It tracks the official StyleX releases

<!-- stylex-compatibility:start -->(currently compatible with StyleX v0.19.2)<!-- stylex-compatibility:end -->

and requires Node.js 20 or newer. For Next.js projects, use @stylexswc/nextjs-plugin instead — it wires this plugin into the Next.js build for you.

Installation

npm install --save-dev @stylexswc/webpack-plugin

The Rust compiler (@stylexswc/rs-compiler) is installed automatically as a dependency. Your application still needs the StyleX runtime:

npm install @stylexjs/stylex

Usage

Add the plugin to your webpack config:

const StylexPlugin = require('@stylexswc/webpack-plugin');
const path = require('path');

const config = (env, argv) => ({
  entry: {
    main: './js/index.js',
  },
  output: {
    path: path.resolve(__dirname, 'dist'),
    filename: '[name].js',
  },
  plugins: [
    new StylexPlugin({
      rsOptions: {
        dev: argv.mode === 'development',
      },
    }),
  ],
  cache: true,
});

module.exports = config;

Then import the carrier stylesheet once at the entry point of your app (e.g. index.js, App.tsx):

import '@stylexswc/webpack-plugin/stylex.css';

The plugin appends the extracted StyleX CSS to this asset during the build. Like a regular CSS file, it must flow through your CSS pipeline, so a css-loader + MiniCssExtractPlugin.loader rule (or webpack's built-in CSS support) has to cover .css files.

The carrier import is a recommendation, not a hard requirement. The plugin also appends tiny per-module CSS imports to every StyleX module, so any part of the bundle that renders a StyleX component pulls the stylesheet in on its own — most builds emit correct CSS even without the carrier. What the carrier adds is a guarantee that doesn't depend on your module graph: the stylesheet is always present and loaded with the entrypoint. That matters when something consumes StyleX output without rendering a StyleX component — plain CSS reading defineVars custom properties (var(--x…)), or injected markup carrying StyleX class names. If styles would actually be lost (no CSS asset exists to receive them at all), the plugin raises a compilation warning; it stays silent as long as the output is correct, carrier or not.

[!IMPORTANT] Migrating from 0.17.x: version 0.18.0 reworks the CSS extraction architecture. The CSS is no longer injected through auto-generated stylex.virtual.css imports — add the import '@stylexswc/webpack-plugin/stylex.css'; carrier import to your app entrypoint (recommended; see above for when you can skip it). Paths embedded in module identifiers are now relative to compiler.context, which changes chunk hashes once and makes builds reproducible across machines.

Plugin Options

Basic Options
rsOptions
  • Type: Partial<StyleXOptions>
  • Optional
  • Description: StyleX compiler options passed to @stylexswc/rs-compiler. For the standard options, see the official StyleX documentation.

[!NOTE] The include and exclude options are exclusive to the Rust compiler and are not available in the official StyleX Babel plugin.

rsOptions.include
  • Type: (string | RegExp)[]
  • Optional
  • Description: Glob patterns or regular expressions selecting the files to transform. When specified, only files matching at least one pattern are transformed. Patterns are matched against paths relative to the current working directory.
rsOptions.exclude
  • Type: (string | RegExp)[]
  • Optional
  • Description: Glob patterns or regular expressions excluding files from the transform. A file matching any exclude pattern is skipped even if it matches an include pattern. Patterns are matched against paths relative to the current working directory.
stylexImports
  • Type: Array<string | { as: string, from: string }>
  • Default: ['stylex', '@stylexjs/stylex']
  • Description: Specifies where StyleX is imported from. Supports both string paths and import aliases.
useCSSLayers
  • Type: boolean
  • Default: false
  • Description: Wraps the generated CSS in cascade layers for better style isolation.
nextjsMode
  • Type: boolean
  • Default: false
  • Description: Enables Next.js-specific optimizations and compatibility features. Leave off unless the plugin is driven by the Next.js integration.
extractCSS
  • Type: boolean
  • Optional
  • Default: true
  • Description: Controls whether the generated CSS is extracted into a separate file.
loaderOrder…

Description from the npm listing.

  • atomic-css
  • css-extraction
  • css-in-js
  • napi-rs
  • react
  • rust
  • stylex
  • swc
  • webpack
  • webpack-plugin

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

@stylexswc/webpack-plugin weekly downloads on npm, last 90 days: 41,983 weekly downloads as of Dec 5, 2026, +196% over 90 days.@stylexswc/webpack-pluginWeekly downloads on npm · Last 90 days41,983downloads / week+196% over 90 days010K20K30K40K50K60K70KSep 6Sep 21Oct 6Oct 21Nov 5Nov 20Dec 5downloads / weekobservedarchived (Internet Archive)no observationsSep 7, 2026 – Dec 5, 2026 · 90 observations · Updated Dec …pluginstats.com
@stylexswc/webpack-plugin weekly downloads on npm, last 90 days: 41,983 weekly downloads as of Dec 5, 2026, +196% over 90 days.

7/30/90-day growth

@stylexswc/webpack-plugin weekly downloads growth on npm: +38.3% over 7 days, +38.4% over 30 days, +196% over 90 days.@stylexswc/webpack-pluginWeekly downloads growth on npm41,983downloads / week now7-day growth+11,618 weekly downloads+38.3%30-day growth+11,657 weekly downloads+38.4%90-day growth+27,780 weekly downloads+196%Growth vs. nearest observation to each baseline date · Updated Dec 5, 2026pluginstats.com
@stylexswc/webpack-plugin weekly downloads growth on npm: +38.3% over 7 days, +38.4% over 30 days, +196% over 90 days.

Ranking history

@stylexswc/webpack-plugin npm ranking history: currently #835 (by weekly downloads).@stylexswc/webpack-pluginnpm ranking · by weekly downloads · Last 90 days#835current rank#200#300#400#500#600#700#800#900#1000Sep 7Sep 22Oct 7Oct 22Nov 6Nov 21Dec 6rankOct 17, 2026 – Dec 6, 2026 · 45 observations · Updated Dec 5, 2026pluginstats.com
@stylexswc/webpack-plugin npm ranking history: currently #835 (by weekly downloads).

Listing placement

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

Listing placement

Webpack plugins349 listings · 18 pages · page 1, #19 (overall #19)
Webpack 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 (592)
Recent weekly downloads observations for @stylexswc/webpack-plugin
Date (UTC)Weekly downloadsChange vs. previous
41,983+1.7K
40,251+2.3K
37,964+2K
35,945+3.2K
32,743+2K
30,705+433
30,272-93
30,365-570
30,935-1.3K
32,188-1.7K
33,925-1.7K
35,586-1.4K
37,031-764
37,795—

Similar npm Webpack plugins plugins

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