MalteJanz / ludtwig

Linter / Formatter for Twig template files which respects HTML and your time.
MIT License
28 stars 3 forks source link

Added parser documentation and more AST implementations #109

Closed MalteJanz closed 2 weeks ago

MalteJanz commented 2 months ago

Added proper documentation for the parser crate and modules that hopefully explains how it works a bit better and references Syntax in rust-analyzer for more details.

Also added some more AST implementations to more easily get some of the syntax tree nodes (e.g. if a HTML tag is self closing or the name of the HTML ending tag). There are still many such implementations missing and you likely still have to reach into the red tree yourself, but let's try to improve this further as more are needed inside Ludtwigs rules.