Skip to main content

jigs_map/
lib.rs

1#![warn(missing_docs)]
2//! HTML and Mermaid map generators for `jigs` pipelines.
3//!
4//! Both renderers read the global `JigMeta` inventory populated by the
5//! `#[jig]` macro. Call from any binary in a crate that defines (or imports)
6//! the jigs you want mapped — the linker pulls them in and the inventory
7//! iteration finds them.
8//!
9//! ```ignore
10//! fn main() -> std::io::Result<()> {
11//!     let dir = env!("CARGO_MANIFEST_DIR");
12//!     std::fs::write(format!("{dir}/map.html"),
13//!         jigs_map::to_html(Some("handle"), "my service", None))?;
14//!     std::fs::write(format!("{dir}/map.md"),
15//!         jigs_map::to_markdown(Some("handle"), "my service"))?;
16//!     Ok(())
17//! }
18//! ```
19
20pub mod html;
21pub mod mermaid;
22
23pub use html::to_html;
24pub use mermaid::{to_markdown, to_mermaid};