Crates.io | binder |
lib.rs | binder |
version | 0.0.2 |
source | src |
created_at | 2022-05-06 22:09:17.976443 |
updated_at | 2022-05-06 22:34:45.288865 |
description | A simple, zero-dependency property-binding framework. |
homepage | https://github.com/trashbyte/binder |
repository | https://github.com/trashbyte/binder |
max_upload_size | |
id | 581870 |
size | 12,245 |
A simple, zero-dependency property-binding framework. It was originally designed to use imgui-rs without drowning in mutable references to everything and constantly fighting with the borrow checker. It uses internal mutability and runtime borrow checking to avoid lifetime issues. Designed to be fully memory- and thread-safe, although there might be bugs since it's brand-new.
pub struct PropHaver {
pub prop: binder::Property<f32>
}
fn use_prop(p: &PropHaver, ui: &imgui::Ui) {
ui.slider("wow what a cool slider", &mut p.prop.bind());
}
This thing is brand-new, so expect bugs and/or API-breaking changes in the near future.
Binder is licensed under the MIT License.