Skip to content
PluginStats

tailwindcss-selection-variant weekly downloads statistics

By philippbosch (4 listings) · npm · Tailwind plugins

Adds a variant for selected text (::selection) to Tailwind CSS

View on npm Fresh · Dec 6, 2026

tailwindcss-selection-variant has 160 recorded weekly downloads on npm, a decrease of 24.2% over the past 30 days, ranking #2539 of 3,247 tracked listings.

Weekly downloads
160
Official API · Dec 5, 2026
7-day growth
+34.5%
+41 weekly downloads
30-day growth
-24.2%
-51 weekly downloads
90-day growth
-59.3%
-233 weekly downloads
Rank
#2539
▼ 60 in 7 days

About tailwindcss-selection-variant

tailwindcss-selection variant

Adds a variant for targeting user-selected text ranges (::selection) to Tailwind CSS.

Example

Given this HTML:

<div class="selection:bg-red-500 selection:text-white">
    Lorem ipsum dolor sit amet
</div>

If the user selects parts of the text within this <div> the selection highlight rendered by the browser will be white text on red background.

This is the relevant part of the generated CSS (simplified):

.selection\:bg-red-500 ::selection {
    background-color: #f56565;
}

.selection\:text-white ::selection {
    color: #fff;
}

Requirements

This plugin requires Tailwind CSS v1.x.

Installation

npm install --save-dev tailwindcss-selection-variant

or

yarn add --dev tailwindcss-selection-variant

Usage

In your tailwind.config.js:

module.exports = {
  // …
  plugins: [
    // …
    require("tailwindcss-selection-variant")
    // …
  ],
  variants: {
    textColor: [
        // …
        'selection',
    ],
    backgroundColor: [
        // …
        'selection',
    ],
  }

  // …
};

Note

Not all CSS properties (and thus Tailwind utilities) can be used with ::selection. See the list of allowable properties on MDN

License

MIT

Description from the npm listing.

  • tailwindcss
  • tailwindcss-plugin
  • selection
  • text selection

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

tailwindcss-selection-variant weekly downloads on npm, last 90 days: 160 weekly downloads as of Dec 5, 2026, -59.3% over 90 days.tailwindcss-selection-variantWeekly downloads on npm · Last 90 days160downloads / week-59.3% over 90 days050100150200250300350Sep 6Sep 21Oct 6Oct 21Nov 5Nov 20Dec 5downloads / weekobservedarchived (Internet Archive)no observationsSep 7, 2026 – Dec 5, 2026 · 90 observations · Updated Dec …pluginstats.com
tailwindcss-selection-variant weekly downloads on npm, last 90 days: 160 weekly downloads as of Dec 5, 2026, -59.3% over 90 days.

7/30/90-day growth

tailwindcss-selection-variant weekly downloads growth on npm: +34.5% over 7 days, -24.2% over 30 days, -59.3% over 90 days.tailwindcss-selection-variantWeekly downloads growth on npm160downloads / week now7-day growth+41 weekly downloads+34.5%30-day growth-51 weekly downloads-24.2%90-day growth-233 weekly downloads-59.3%Growth vs. nearest observation to each baseline date · Updated Dec 5, 2026pluginstats.com
tailwindcss-selection-variant weekly downloads growth on npm: +34.5% over 7 days, -24.2% over 30 days, -59.3% over 90 days.

Ranking history

tailwindcss-selection-variant npm ranking history: currently #2539 (by weekly downloads).tailwindcss-selection-variantnpm ranking · by weekly downloads · Last 90 days#2539current rank#1600#1800#2000#2200#2400#2600Sep 7Sep 22Oct 7Oct 22Nov 6Nov 21Dec 6rankOct 18, 2026 – Dec 6, 2026 · 44 observations · Updated Dec 5, 2026pluginstats.com
tailwindcss-selection-variant npm ranking history: currently #2539 (by weekly downloads).

Listing placement

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

Listing placement

Tailwind plugins292 listings · 15 pages · page 6, #2 (overall #102)
Tailwind 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 tailwindcss-selection-variant
Date (UTC)Weekly downloadsChange vs. previous
160+2
158-4
162+11
151+11
140+31
109+5
104-15
119-7
126+5
121-9
130+17
113+1
112+8
104—

Similar npm Tailwind plugins plugins

All 20 tailwindcss-selection-variant 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/tailwindcss-selection-variant. First seen Oct 16, 2026; last successful collection Dec 6, 2026. See the methodology.