pub trait Document {
// Required method
fn ty() -> Type;
}
Expand description
A type that can be pretty-printed by Doku.
Usually you’ll get this by adding #[derive(Document)]
to your type:
use doku::Document;
#[derive(Document)]
struct Foo;
… but implementing it manually will be required if you’re using a custom serializer / deserializer (see: the examples directory).