Skip to content

[php-wasm-logger] Remove unnecessary @php-wasm/node-polyfills dependency#3471

Draft
mho22 wants to merge 1 commit intotrunkfrom
remove-node-polyfill-from-php-wasm-logger
Draft

[php-wasm-logger] Remove unnecessary @php-wasm/node-polyfills dependency#3471
mho22 wants to merge 1 commit intotrunkfrom
remove-node-polyfill-from-php-wasm-logger

Conversation

@mho22
Copy link
Copy Markdown
Collaborator

@mho22 mho22 commented Apr 6, 2026

Motivation for the change, related issues

The @php-wasm/logger package imports @php-wasm/node-polyfills solely for the CustomEvent polyfill (used in log-event.ts and collect-php-logs.ts). However, CustomEvent has been a native global since Node.js v19, and this project requires Node.js >= 20.10.0. The import is dead weight — it pulls in unnecessary polyfills (File, Blob, etc.) that the logger never uses.

Implementation details

  • Removed the import @php-wasm/node-polyfills side-effect import from packages/php-wasm/logger/src/index.ts
  • The @php-wasm/node-polyfills dependency in the dist package.json is auto-generated during build and will be dropped automatically.

Testing Instructions (or ideally a Blueprint)

CI

@mho22 mho22 added [Package][@php-wasm] Logger dependencies Pull requests that update a dependency file labels Apr 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file [Package][@php-wasm] Logger

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant