[PR #6623] refactor: use structuredClone instead of JSON parse/stringify #12010

Open
opened 2026-02-16 18:16:56 -05:00 by yindo · 0 comments
Owner

Original Pull Request: https://github.com/anomalyco/opencode/pull/6623

State: open
Merged: No


Replace JSON.parse(JSON.stringify(x)) with structuredClone(x) for deep cloning in publish scripts.

structuredClone is the modern native API for this - cleaner and handles more edge cases correctly.

**Original Pull Request:** https://github.com/anomalyco/opencode/pull/6623 **State:** open **Merged:** No --- Replace `JSON.parse(JSON.stringify(x))` with `structuredClone(x)` for deep cloning in publish scripts. `structuredClone` is the modern native API for this - cleaner and handles more edge cases correctly.
yindo added the pull-request label 2026-02-16 18:16:56 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#12010