Skip to content

Publish a release with the patched sharp, svgo, and deepmerge-ts pins #669

Todo

Description

@zachary-onix

Thanks for maintaining Compress. The Current branch already pins sharp@0.35.5, svgo@4.1.0, and deepmerge-ts@8.0.2. The latest npm releases (astro-compress@2.4.3 and @playform/compress@0.2.5, from 2026-08-07) still pin the older versions, which these advisories cover:

Because the dependencies are exact-pinned, users cannot pick up the fixes without overrides. Could you publish a new release from Current? Thank you!

Activity

  1. NikolaRHristov commented on Nov 25, 2026

    @NikolaRHristov
    Member

    Hi, @zachary-onix!

    Thank you for this issue.

    Until there's a release from Current, you can pin the three yourself. The override can be scoped to only this package, so nothing else in your tree moves.

    With npm, in the root package.json:

    {
    	"overrides": {
    		"@playform/compress": {
    			"sharp": "0.35.5",
    			"svgo": "4.1.0",
    			"deepmerge-ts": "8.0.2"
    		}
    	}
    }

    Same block with astro-compress as the key if you're on that one instead.

    With pnpm the parent>child syntax does the same scoping:

    {
    	"pnpm": {
    		"overrides": {
    			"@playform/compress>sharp": "0.35.5",
    			"@playform/compress>svgo": "4.1.0",
    			"@playform/compress>deepmerge-ts": "8.0.2"
    		}
    	}
    }

    On pnpm 10 those can also live in pnpm-workspace.yaml under overrides:. Yarn and bun take the same idea as resolutions / overrides, keyed @playform/compress/sharp.

    Then reinstall and confirm it landed, npm ls sharp svgo deepmerge-ts or pnpm why sharp.

    Two things to keep in mind:

    deepmerge-ts is a major jump here, 7.1.5 → 8.0.2. The only breaking change in v8 is that Map values are deep-merged by default, so merging the options objects isn't affected, but if you'd rather not take a major in one go, override sharp and svgo first, build, then add deepmerge-ts.

    sharp is a native dependency, so the override only takes effect after a clean reinstall, if the old binary sticks around, remove node_modules (and the lockfile entry) and install again.

    Both are stopgaps: the pins are already on Current, so the next release carries them and the overrides can come straight back out.

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

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions