Expand description
Procedural macros to support the fundle crate. See fundle for more information.
§Macros
§#[bundle]
Transforms structs into type-safe builders with dependency injection support.
ⓘ
#[fundle::bundle]
pub struct AppState {
logger: Logger,
database: Database,
}Generates builder methods and a select macro for dependency access.
§#[deps]
Creates dependency parameter structs with automatic From<T> implementations.
ⓘ
#[fundle::deps]
pub struct ServiceDeps {
logger: Logger,
database: Database,
}Generates From<T> where T: AsRef<Logger> + AsRef<Database>.
§#[newtype]
Creates newtype wrappers with automatic trait implementations.
ⓘ
#[newtype]
pub struct DatabaseLogger(Logger);Generates Clone, From<T: AsRef<Logger>>, Deref, and DerefMut.