Clone in a terminal:
Commit 5809d9b
Johan Mattsson - 2026-06-09T21:49:21+00:00
5809d9b60bfe1ec449eb318a7127fe1649939be1johan.mattsson.m@gmail.com

Update README.md

Changed files (2)

Diff

diff --git a/.gitignore b/.gitignoreindex 873b296..34aa146 100644--- a/.gitignore+++ b/.gitignore@@ -1,3 +1,2 @@-target target/ pkg/diff --git a/README.md b/README.mdindex f9838be..6788acb 100644--- a/README.md+++ b/README.md@@ -3,8 +3,7 @@ The key concept and idea behind the design is that HTML content is managed as strings and the code is compiled to WebAssembly. There is no Domain Specific Language, just plain Rust with a little bit of glue code that calls the WebAssembly-functions in onclick handlers (and also other event handlers). The HTML code is-generated using the `kaja_html_macro` crate.+functions in onclick handlers (and also other event handlers).  There are also a number of helper functions available to make it easier to interact with the browser.@@ -19,12 +18,13 @@ fn increment_click_counter() { }  fn main() {-    // make sure functions annotated with `#[callback]` are available as global functions on the DOM+    // Init callbacks tomake sure functions annotated with `#[callback]`+    // are available as global functions on the DOM     init_callbacks();       let content = html! {{         <div class="click-count"></div>-        <button onclick="incrementClickCounter">Click me</button>+        <button onclick="incrementClickCounter()">Click me</button>     }};      inner_html(".main-content", content);@@ -37,23 +37,10 @@ fn main() { For more example see: the crates `kaja-html-macro` and `kaja-callback-macro` or look in the examples directory. -## Functions Needed-Add these crates to your project's `Cargo.toml` file:--```toml-[dependencies]-gloo = "0.12.0"-gloo-console = "0.4.0"-kaja-html-macro = "1.0.3"-kaja-callback-macro = { version = "0.1.0" }-wasm-bindgen = "0.2.122"-web-sys = { version = "0.3.99", features = ["Document", "HtmlDocument", "Element", "HtmlElement", "HtmlInputElement", "NodeList"] }-serde = { version = "1.0", features = ["derive"] }-serde-wasm-bindgen = "0.5"-inventory = "0.3.24"-js-sys = "0.3"-wasm-bindgen-futures = "0.4.72"-```+## The Macros+The HTML code is generated using the `kaja_html_macro` crate. The callback+functions are definedusing the `kaja_callback_macro` crate. Helper functions+are added in this crate and reexportedfrom the `kaja_web::prelude` module.  ## Author and Contact - Written by Johan Mattsson

Contact

Email: johan.mattsson.m@gmail.com
Mastodon: typo.social/@birdfont
GitHub: johanmattssonm
LinkedIn: johan-mattsson-2ab324112