paulirish/matchMedia.js
matchMedia polyfill for testing media queries in JS observed · 2026-08-28
Health v2 · maintenance only
23/100
- Activity 0
- Release rhythm 8
- Longevity 100
How is this computed?
round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10) — computed 2026-09-03. Adoption (stars, forks) is never an input.
- gap_med: n/a
- age_days: 5633
- days_rel: n/a
- days_push: 2080
- n_releases_24m: 0
Adoption not part of the score
2361 stars · 278 forks observed · 2026-08-28
What it is AI-extracted, prompt v1, taxonomy v1, 2026-08-30, confidence not recorded
A JavaScript polyfill for the window.matchMedia() API, allowing developers to test whether CSS media types or media queries apply in browsers lacking native support. It also offers an addListener module for reacting to media query changes.
Use cases
- test media queries in javascript
- polyfill matchMedia in old browsers
- detect mobile screen width in js
- check device orientation in javascript
- run responsive dom scripting based on media queries
When to choose
- supporting legacy browsers without native matchMedia support
- building responsive scripts that need media query testing in old IE or older Safari
When to avoid
- targeting only modern browsers that natively support matchMedia
- starting a new project where native APIs suffice
Facets
library · maturity maintenance
developer-tools ui-components web-development frontend cross-platform browser polyfill media-queries matchmedia responsive-design browser-compatibility javascript
1 source
- readme: https://github.com/paulirish/matchMedia.js · fetched 2026-08-28 · dcf9e106f025
Member repositories
| Repository | Role | Health v2 |
|---|---|---|
| paulirish/matchMedia.js | main | 23 |
For agents
markdown · JSON · MCP: product_card(name="paulirish/matchMedia.js")
Data as of 2026-08-30T08:39:29.467469+00:00 · Report a problem