Skip to content

fix: allow > in text nodes - #141

Open
yeskunall wants to merge 1 commit into
tree-sitter:masterfrom
tau-engineering:fix/allow-gt-in-text-a087256bfd35301b
Open

yeskunall wants to merge 1 commit into
tree-sitter:masterfrom
tau-engineering:fix/allow-gt-in-text-a087256bfd35301b

Conversation

@yeskunall

Copy link
Copy Markdown

Per the HTML tokenizer data state, only < and & are special in text content; a bare > is ordinary character data. Excluding > from the text token made a stray > (such as the => arrow inside a <pre> block) start an ERROR node that swallowed the rest of the element, breaking parsing and syntax highlighting downstream.

Ref: zed-industries/zed#60460.

Per the HTML tokenizer data state, only < and & are special in text content; a bare > is ordinary character data. Excluding > from the text token made a stray > (such as the => arrow inside a <pre> block) start an ERROR node that swallowed the rest of the element, breaking parsing and syntax highlighting downstream.
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