Skip to content
JS
Package

refractor

Lightweight, robust, elegant virtual syntax highlighting using Prism

v5.0.0, 11 Mar 2025MITESM onlyTypes: NoneReact
$ npm install refractor

Key numbers

As of 25 Sept 2026
Weekly downloads
7.2m
+124% over 12 months
Gzip bundle size
-
No Bundlephobia data
Dependencies
4
Direct, from package.json
Last release
1 year ago
v5.0.0
GitHub stars
870
48 forks
Open issues / PRs
0 / 0
Contributors
-
Commits, last 52 weeks
0

Downloads

Last week 2026-09-15 to 2026-09-21
05m10m15mSept 2025Mar 2026Sept 2026High 10.3m (25 Aug 2026)Low 2.4m (23 Dec 2025)
Weekly npm downloads, one point per week, weeks starting 23 Sept 2025 to 15 Sept 2026. The y axis starts at zero.

7,177,609 downloads last week, 36,249,672 in the last month. The 12-month change of +124% compares the average of the last 4 weeks with the first 4 weeks of the series.

Releases, last 12 months
042 in total
Latest version
5.0.0, 11 Mar 20251 year ago
First published
2 Aug 2017
Last push to GitHub
11 Mar 2025562 days before the snapshot
Repository archived
No
Open issues
0
Open pull requests
0
Commits, last 52 weeks
0
Dependents on npm
280

Major versions

  1. v5 first release 5.0.0, 11 Mar 2025
  2. v4 first release 4.0.0, 8 May 2021
  3. v3 first release 3.0.0, 6 Apr 2020
  4. v2 first release 2.0.0, 7 Nov 2017
  5. v1 first release 1.0.0, 2 Aug 2017

Recent releases

VersionPublished
5.0.011 Mar 2025
4.9.011 Mar 2025
4.8.128 Feb 2023
4.8.023 Aug 2022
4.7.012 May 2022
4.6.017 Apr 2022
3.6.025 Feb 2022
4.5.019 Feb 2022
4.4.06 Jan 2022
4.3.022 Nov 2021
4.2.28 Nov 2021
3.5.08 Oct 2021
4.2.122 Sept 2021
4.2.017 Sept 2021
Module format
ESM onlyFrom package.json type, main and exports fields
TypeScript types
None
Node.js engine range
Not declared
Runtimes
-
Unpacked size (npm)
1.0 MB
Dependencies (4)
hastscript@types/hast@types/prismjsparse-entities
npm install refractor

CDN

jsDelivr: 687.1k requests in 30 days
  • jsDelivrhttps://cdn.jsdelivr.net/npm/refractor@5.0.0/
  • unpkghttps://unpkg.com/refractor@5.0.0/
  • esm.shhttps://esm.sh/refractor@5.0.0
Sources: npm registry, npm downloads API, GitHub API, jsDelivr. Data fetched 25 Sept 2026.

Indexability: Indexed.