Hirola is an un-opinionated webf ramework that is focused on simplicity and predictability.
global-state
.We are going to create a simple counter program.
cargo new counter
With a new project, we need to create an index file which is the entry point and required by trunk
cd counter
Create an index.html
in the root of counter. Add the contents below
html
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<title>Hirola Counter</title>
</head>
</html>
Lets add some code to src/main.rs
```rust use hirola::prelude::*;
fn counter(app: &HirolaApp) -> Dom { let count = Signal::new(0); html! {
}
} fn main() { let app = HirolaApp::new(); app.mount("body", counter); } ```
Now lets run our project
trunk serve
You should be able to get counter running: Live Example
Check out Hirola Docs written with Hirola itself!
Here are some extensions for hirola:
| Status | Goal | Labels |
| :----: | :------------------------------------------------------------------------ | ------------ |
| ✔ | Write code that is declarative and easy to follow | ready
|
| ✔ | Allow extensibility via mixins | ready
|
| 🚀 | Standardize Components | inprogress
|
| 🚀 | SSR First Approach | inprogress
|
| 🚀 | Hydration | todo
|
| 🚀 | Serverside integrations | todo
|
This API will certainly change.
Go to examples
and use trunk
$ trunk serve
You need need to have rust
, cargo
and trunk
installed.
License: MIT