active-dom

Crates.ioactive-dom
lib.rsactive-dom
version0.1.0
sourcesrc
created_at2024-02-25 10:00:19.919158
updated_at2024-02-25 10:00:19.919158
descriptionReactive wasm web framework in Rust.
homepage
repositoryhttps://github.com/mdmahikaishar/active-dom
max_upload_size
id1152348
size21,166
Md Mahi Kaishar (mdmahikaishar)

documentation

README

Active DOM

Rust Wasm

Reactive wasm web framework in Rust.

Usage

Add this crate to your Cargo.toml file:

[dependencies]
active_dom = "0.1.0"
// main.rs
use active_dom::{create_signal, mount, DOM};

fn main() {
    mount(|ctx| {
        let count = create_signal(ctx, 1);

        DOM::new("div")
            .child(
                &DOM::new("button")
                    .text("-")
                    .on("click", move |_| count.set(count.get() - 1))
            )
            .dyn_text(ctx, move || count.get().to_string())
            .child(
                &DOM::new("button")
                .text("+")
                .on("click", move |_| count.set(count.get() + 1))
            )
    });
}
trunk serve

Contributing

Contributions are welcome! I would like you to contribute in this project.

Roadmap

This project is in its early stages, and there are many missing features that need implementation. Check the Issues section for a list of features, enhancements, and bug fixes that are planned.

Inspired Of

Greg Johnston's youtube channel and git repo simple-framework.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Commit count: 0

cargo fmt