Repository navigation
Conversation
Replace Moonshiner and NYC with Vitest browser mode, Playwright, and Istanbul coverage to remove the unpatched extract-zip and vulnerable glob dependency chains. Drop unnecessary Rollup resolver and test bundling plugins to remove deepmerge. Use patched minimatch 11 only under ESLint until upstream adopts it. Preserve all 128 browser tests, 100% coverage thresholds, published declarations, and byte-identical bundle output while bringing the full npm audit to zero findings.
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.
Why
The dependency refresh left 13 npm audit findings and four open Dependabot alerts. The remaining
extract-zipanddeepmergevulnerabilities have no patched releases, so upgrading the existing toolchain alone cannot clear them.Approach
Move the existing browser suite from Moonshiner/NYC to Vitest browser mode with Playwright and Istanbul coverage. That removes the vulnerable browser downloader and old glob/coverage dependency chains. The 24 test files retain their existing assertions and fixtures; only their runner imports change.
Remove unnecessary Rollup resolver/CommonJS plugins and obsolete test bundling configuration. The library has no external runtime imports, so its bundle does not need those plugins, and dropping the resolver removes
deepmerge. Keep one ESLint-scoped override to patchedminimatch11.0.7 because ESLint and its config matcher still declare vulnerable 10.x ranges. Remove that override when upstream adopts a patched range.CI installs Chromium and its system dependencies explicitly. The existing test script names, 100% coverage thresholds, and LCOV output remain available, and the Babel configuration uses ES modules.
Evidence
A clean install reports zero vulnerabilities in both full and production npm audits. All 128 tests pass in real Chromium, with exactly the same coverage totals: 488 statements, 394 branches, 152 functions, and 408 lines, all at 100%.
Lint, declaration builds, type checks, and workflow validation pass. The simplified build produces a byte-for-byte identical bundle, and a separate consumer type-checks chained interactions against the packed npm artifact. Library source is unchanged.
The existing GitHub alerts remain attached to
mainuntil this change is merged and rescanned.