File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change 11# HTML AST
2- A HTML AST parser written in php. Inspired by the AST parser in TempestPHP (written by Brett Roose).
2+ An HTML AST (Abstract Syntax Tree) parser written in php. Inspired by the AST parser in TempestPHP (written by Brett Roose).
33
44It has a built-in lexer to parse the html, and then a AST parser to convert it into a tree structure.
55Finally, it comes with a printer to output properly formatted HTML (indented).
@@ -17,4 +17,9 @@ $nodeTree = $ast->parse();
1717
1818//and if you want to output the resulting HTML
1919echo Printer::make()->render($html);
20- ```
20+ ```
21+
22+ ## Todo
23+ * [ ] Add line numbers to lexer
24+ * [ ] Add html validator to ensure HTMl structure is valid
25+ * [ ] Add node visitors to allow changing HTML ?
You can’t perform that action at this time.
0 commit comments