npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@rolldown/plugin-styled-jsx

v0.1.1

Published

Rolldown plugin for styled-jsx CSS scoping

Downloads

224

Readme

@rolldown/plugin-styled-jsx npm

Rolldown plugin for styled-jsx CSS scoping.

This plugin utilizes Rolldown's native magic string API instead of Babel and is more performant than using styled-jsx/babel with @rolldown/plugin-babel.

Install

pnpm add -D @rolldown/plugin-styled-jsx

Usage

import styledJsx from '@rolldown/plugin-styled-jsx'

export default {
  plugins: [
    styledJsx({
      // options
    }),
  ],
}

Options

browsers

  • Type: Targets (from lightningcss)
  • Default: undefined

Target browser versions for CSS transpilation. See the lightningcss documentation for details.

styledJsx({
  browsers: {
    chrome: 95 << 16,
    firefox: 90 << 16,
  },
})

sourceMap

  • Type: boolean
  • Default: true in development, false otherwise

Generates inline source maps for scoped CSS, allowing browser DevTools to map styles back to where they are defined in the source file.

styledJsx({
  sourceMap: true,
})

Benchmark

Results of the benchmark that can be run by pnpm bench in ./benchmark directory:

  name                              hz      min      max     mean      p75      p99     p995     p999     rme  samples
· @rolldown/plugin-styled-jsx  10.9402  89.9217  96.5430  91.4056  91.2763  96.5430  96.5430  96.5430  ±1.49%       10
· @rolldown/plugin-babel        4.3779   223.52   238.96   228.42   230.16   238.96   238.96   238.96  ±1.65%       10
· @rollup/plugin-swc            9.4885   103.62   109.31   105.39   105.83   109.31   109.31   109.31  ±1.11%       10

@rolldown/plugin-styled-jsx - bench/styled-jsx.bench.ts > Styled JSX Benchmark
  1.15x faster than @rollup/plugin-swc
  2.50x faster than @rolldown/plugin-babel

The benchmark was ran on the following environment:

OS: macOS Tahoe 26.3
CPU: Apple M4
Memory: LPDDR5X-7500 32GB

License

MIT

Credits

The implementation is based on swc-project/plugins/packages/styled-jsx (Apache License 2.0). Test cases are also adapted from it.