Skip to content

Fix preact-cli config loading on Node 24 - #461

Closed
jiwon85 wants to merge 1 commit into
mainfrom
fix/preact-cli-node24
Closed

jiwon85 wants to merge 1 commit into
mainfrom
fix/preact-cli-node24

Conversation

@jiwon85

@jiwon85 jiwon85 commented Sep 29, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • preact-cli loads preact.config.js via the unmaintained esm package, which crashes on Node 24
  • Switch all three preact.config.js files to plain CommonJS exports
  • Patch preact-cli to require() the config directly, falling back to esm only if that fails

Test plan

  • donate-button-v4: dev build and widget render verified on Node 24
  • donate-button / donate-button-next: patch applies cleanly (a separate, pre-existing dependency issue keeps these two non-functional regardless of Node version)
Screenshot 2026-09-29 at 3 26 08 PM

preact-cli uses the abandoned esm package to load preact.config.js,
which crashes under Node 24. Switch configs to CommonJS and patch
preact-cli to require() them directly instead.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@vercel

vercel Bot commented Sep 29, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
donate-button Ready Ready Preview Sep 29, 2026 10:29pm UTC

Request Review

@jiwon85

jiwon85 commented Oct 1, 2026

Copy link
Copy Markdown
Contributor Author

tried testing on staging, and I can't simulate a charge eventually failing, only blocked at frontend synchronous, but I don't think it's harmful to see if it works in prod

@jiwon85

jiwon85 commented Oct 1, 2026

Copy link
Copy Markdown
Contributor Author

Closing in favor of #462

@jiwon85 jiwon85 closed this Oct 1, 2026

This branch was successfully deployed

1 active deployment
Preview — 22f19da4 Deployed Sep 29, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant