| Crates.io | markdown-it-lazyload |
| lib.rs | markdown-it-lazyload |
| version | 0.1.1 |
| created_at | 2025-01-01 08:05:56.082901+00 |
| updated_at | 2025-01-01 08:22:15.41135+00 |
| description | A markdown-it plugin to add lazy to image tags' loading property |
| homepage | |
| repository | https://github.com/yoshinorin/markdown-it-rust-plugins |
| max_upload_size | |
| id | 1500660 |
| size | 20,306 |
A markdown-it.rs plugin to add lazy to loading property in <img> tag.
let mut parser = markdown_it::MarkdownIt::new();
markdown_it::plugins::cmark::add(parser);
markdown_it_lazyload::add(parser);
md.parse("").render();
// <p><img src="https://example.com/example.png" alt="Rust" loading="lazy"></p>
See the tests for more examples.