Issue 268
tech-debt: Use Payload's deepMerge and Lexical-to-plaintext instead of our copies
Back to our planDone
cmstech-debtpriority: low
Problem
Two small helpers copy what Payload 3.91 already exports:
src/modules/directory/ui/lexicalToPlainText.tsvsconvertLexicalToPlaintextfrom@payloadcms/richtext-lexical/plaintext(docs, opens in a new tab)src/platform/lib/deepMerge.ts(has@ts-nocheck, which the guidelines ban) vsdeepMergefrompayload/shared
Proposed fix
Use Payload's exports and delete ours. Check the FAQ JSON-LD text keeps the same line breaks, and that the two callers of deepMerge (site/cms/link.ts, linkGroup.ts) get the same result with arrays.
Findings (#262): native fits; both exports verified in the 3.91 packages.
Acceptance criteria
- Not done: Both files and their tests are gone; callers use Payload's
- Not done: FAQ JSON-LD and link fields unchanged
Area
cms
Priority
Low
Generated by Claude Code, opens in a new tab