#incremental #parsing #html

tree-sitter-html

html grammar for the tree-sitter parsing library

1 unstable release

0.19.0 Dec 21, 2021

#160 in Text editors

Download history 1394/week @ 2023-01-18 1850/week @ 2023-01-25 1267/week @ 2023-02-01 1341/week @ 2023-02-08 2065/week @ 2023-02-15 1986/week @ 2023-02-22 2019/week @ 2023-03-01 1656/week @ 2023-03-08 1620/week @ 2023-03-15 1906/week @ 2023-03-22 587/week @ 2023-03-29 444/week @ 2023-04-05 378/week @ 2023-04-12 406/week @ 2023-04-19 420/week @ 2023-04-26 362/week @ 2023-05-03

1,644 downloads per month
Used in 5 crates

MIT license

71KB
2.5K SLoC

C 2K SLoC C++ 259 SLoC // 0.0% comments JavaScript 107 SLoC Rust 43 SLoC // 0.1% comments Scheme 17 SLoC

tree-sitter-html

Build Status Build status

HTML grammar for tree-sitter.

References


lib.rs:

This crate provides html language support for the tree-sitter parsing library.

Typically, you will use the language function to add this language to a tree-sitter Parser, and then use the parser to parse some code:

let code = "";
let mut parser = tree_sitter::Parser::new();
parser.set_language(tree_sitter_html::language()).expect("Error loading html grammar");
let tree = parser.parse(code, None).unwrap();

Dependencies

~1.4–2MB
~53K SLoC