Conversation
…grade deps - Replace mocha with vitest for test runner (fixes serialize-javascript transitive dep from mocha) - Upgrade webpack 5.75→5.105, webpack-cli 5.0→6.0 - Add npm override for serialize-javascript ^7.0.3 (fixes transitive dep from webpack→terser-webpack-plugin) - Upgrade @types/node ^18→^22 (required by vitest 4.x) - Add skipLibCheck to tsconfig (vitest/vite types need newer TS features) - Exclude test files from tsc (vitest runs TypeScript directly) - Add vitest.config.ts with globals and onig.js alias - Remove compiled test output from git (no longer needed) Resolves serialize-javascript RCE vulnerability (GHSA issue #25). npm audit now reports 0 vulnerabilities. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
lszomoru
approved these changes
Feb 28, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Dependabot alert #25:
serialize-javascript6.0.2 is vulnerable to RCE viaRegExp.prototype.flagsandDate.prototype.toISOString(). The earliest fixed version is 7.0.3.The vulnerable dependency was introduced via two paths:
mocha 10.8.2 → serialize-javascript 6.0.2webpack 5.x → terser-webpack-plugin → serialize-javascript 6.0.2Solution
tsc.overridesforserialize-javascript: ^7.0.3— needed becauseterser-webpack-pluginstill pins^6.0.2@types/node^18 → ^22 (required by vitest 4.x)skipLibCheckto tsconfig (standard practice; vitest/vite types reference newer TS features)tsccompilation (vitest handles them directly)vitest.config.tswith globals mode and an alias to resolve the emscripten-generatedonig.jsVerification
Resolves #25.