Skip to content

Override refractor 3.6.0's prismjs dependency#605

Merged
simmerer merged 2 commits intomasterfrom
refractor-prismjs-override
Aug 25, 2025
Merged

Override refractor 3.6.0's prismjs dependency#605
simmerer merged 2 commits intomasterfrom
refractor-prismjs-override

Conversation

@simmerer
Copy link
Copy Markdown
Collaborator

@simmerer simmerer commented Aug 25, 2025

Updating to refractor 4.x or 5.x introduces breaking changes for react-syntax-highlighter (see #521 for example)

A simpler fix for now is to use an npm override to ensure that the old version of refractor doesn't bring in the vulnerable version of prismjs.

This is a followup to #599, where simply updating this project's prismjs dep didn't take care of the vulnerable version being brought in as a transitive dep of refractor 3.6.0.

@simmerer simmerer changed the title Override refractor 3.6.0 Override refractor 3.6.0's prismjs dependency Aug 25, 2025
@codecov
Copy link
Copy Markdown

codecov Bot commented Aug 25, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 96.02%. Comparing base (60837e9) to head (fc0a1c7).
⚠️ Report is 10 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #605   +/-   ##
=======================================
  Coverage   96.02%   96.02%           
=======================================
  Files          11       11           
  Lines         327      327           
  Branches      130      130           
=======================================
  Hits          314      314           
  Misses         12       12           
  Partials        1        1           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@simmerer simmerer merged commit 1e95cdd into master Aug 25, 2025
4 checks passed
lodinukal pushed a commit to lodinukal/react-syntax-highlighter that referenced this pull request Aug 26, 2025
…ighter#605)

* override refractor 3.6.0's prismjs dependency

* rebuild demos
lodinukal pushed a commit to lodinukal/react-syntax-highlighter that referenced this pull request Aug 26, 2025
…ighter#605)

* override refractor 3.6.0's prismjs dependency

* rebuild demos
lodinukal pushed a commit to lodinukal/react-syntax-highlighter that referenced this pull request Aug 26, 2025
…ighter#605)

* override refractor 3.6.0's prismjs dependency

* rebuild demos
@ivasilov
Copy link
Copy Markdown

FYI this PR doesn't fix the issue - you only solved it for this repo, overrides is ignored when running npm i react-syntax-highlighter.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants