Skip to content

Phase 17: GFM table header/delimiter column-count parity (v0.1.14) - #14

Merged
lidonggui merged 1 commit into
mainfrom
phase-17-table-header-delim-columns
Sep 21, 2026
Merged

lidonggui merged 1 commit into
mainfrom
phase-17-table-header-delim-columns

Conversation

@lidonggui

Copy link
Copy Markdown
Contributor

Summary

  • Tighten looksLikeTable so a GFM table opens only when the delimiter row’s cell count equals the header’s (micromark/GFM parity: leading/trailing pipes optional; empty edge cells from outer pipes ignored).
  • Mismatched counts stay a paragraph; ragged body rows with matching header/delimiter still form a table (body absorption unchanged).
  • Phase 14 paragraph-interrupt uses the same tightened look-ahead. Docs + bump to 0.1.14.

Test plan

  • pnpm verify (typecheck + test + build) green locally
  • New Phase 17 cases: delim < header / delim > header → paragraph; matching → table; ragged body → table; mismatched does not interrupt as table
  • CI green (or merge after verify if no required checks, matching prior phases)

looksLikeTable only when delimiter cell count equals header (micromark/GFM:
leading/trailing pipes optional, empty edge cells ignored). Mismatched counts
stay paragraph; ragged body with matching header/delim still table.
@lidonggui
lidonggui merged commit 4113359 into main Sep 21, 2026
1 check passed
@lidonggui
lidonggui deleted the phase-17-table-header-delim-columns branch September 21, 2026 18:56
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