eventify

Crates.ioeventify
lib.rseventify
version0.1.0-alpha.0
sourcesrc
created_at2023-11-21 15:18:26.577757
updated_at2023-11-26 23:36:14.324019
descriptionA utility library for variety of event-based programming patterns.
homepage
repositoryhttps://github.com/jacobrgreen114/eventify-rs
max_upload_size
id1044327
size27,925
Jacob Green (jacobrgreen114)

documentation

README

eventify

A utility library for variety of event-based programming patterns.

*** Eventify is still in early development, and is not yet ready for use in production! ***

Examples

Events

use eventify::event::*;

fn main() {
    let event = Event::new();
    
    let hook = event.hook(|_| {
        println!("Event fired!");
    });
    
    event.emit(&());
}

Properties

use eventify::property::*;

fn main() {
    let property = Property::new("".to_string());

    let binding = property.bind(|value| {
        println!("Property changed to: {}", value);
    });

    *property.write().unwrap() = "Hello, world!".to_string();
}
Commit count: 10

cargo fmt