Skip to content

Docs: Clarify HTML Processor serialization output#74

Draft
sirreal wants to merge 1 commit into
trunkfrom
docs/html-api-token-output
Draft

Docs: Clarify HTML Processor serialization output#74
sirreal wants to merge 1 commit into
trunkfrom
docs/html-api-token-output

Conversation

@sirreal

@sirreal sirreal commented Jun 29, 2026

Copy link
Copy Markdown
Owner

Summary

  • Clarifies create_fragment() construction failure versus later parser errors.
  • Documents serialize() and normalize() as normalization APIs, not queued-mutation readback.
  • Documents serialize_token() as the API for token-loop rewrites and warns against discarding accumulated output with a later normalize( $html ) call.

Verification

  • php -l src/wp-includes/html-api/class-wp-html-processor.php
  • git diff --check

Trac ticket: TBD

Use of AI Tools

AI assistance: Yes
Tool(s): Codex
Used for: Reviewing the generated documentation-improvement branch, splitting evidence-backed changes into focused PRs, drafting wording, and running local verification. Final changes were reviewed against source behavior and experiment notes.

@sirreal sirreal added this to the HTML API docs milestone Jun 29, 2026
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