MarshallOfSound

#47598: build: write abi version to published npm package

Merged
Created: Jun 28, 2025, 7:38:14 PM
Merged: Jun 30, 2025, 5:01:09 PM
3 comments
Target: main

This adds a helper file that makes it easier for tools like node-abi to determine the ABI version of an otherwise unknown package. node-abi is a pretty massive source of annoyance for folks, even for seasoned Electron App developers it's an annoying thing you need to keep ensuring you update. Package managers don't make it easy, so instead to mitigate this as much as possible I'm proposing we write this file to disk, and then in node-abi if we are resolving a version we don't recognize we try to find this file on disk for a matching electron version. If it matches, and it exists, we can serve it and app developers don't need to do any package manager shenanigans.

Notes: Added abi_version file to the npm package

Backports

No Backports Requested

This pull request doesn't have any backports requested or created for older release branches.

What are backports?

Backports are copies of changes made to the main branch that are applied to older release branches. They ensure that bug fixes and important changes are available in maintained older versions of Electron.

Semver Impact

Major
Breaking changes
Minor
New features
Patch
Bug fixes
None
Docs, tests, etc.

Semantic Versioning helps users understand the impact of updates:

  • Major (X.y.z): Breaking changes that may require code modifications
  • Minor (x.Y.z): New features that maintain backward compatibility
  • Patch (x.y.Z): Bug fixes that don't change the API
  • None: Changes that don't affect using facing parts of Electron