Crates.io | highlight-ez |
lib.rs | highlight-ez |
version | 0.2.6 |
source | src |
created_at | 2024-04-12 17:09:53.650536 |
updated_at | 2024-05-01 20:17:19.343894 |
description | Easy Syntax Highlighting with HTML output |
homepage | |
repository | https://github.com/Mordanis/highlight-ez |
max_upload_size | |
id | 1206523 |
size | 20,611 |
Create HTML renderings of code with highlighting using tree-sitter
The general workflow of this is to simplify the workflow of creating pretty html code blocks using tree-sitter.
let my_pyblock = r#"def fib(a):
if a = 1:
return 1
else:
return fib(a - 1)"#;
let lang = TargetLanguage::Python;
let html = render_html(my_pyblock, lang);