mirror of
https://github.com/adoyle0/thaw.git
synced 2025-01-23 14:29:22 -05:00
3684f5961b
* demo: refactor docs * demo: refactor docs * demo: refactor guide docs * chore: workflow add listens to the demo_markdown * demo: refactor mobile docs
28 lines
375 B
Markdown
28 lines
375 B
Markdown
# Usage
|
|
|
|
You just need to import thaw and use it.
|
|
|
|
```rust
|
|
// Import all
|
|
use thaw::*;
|
|
// Import on Demand
|
|
use thaw::{Button, ButtonVariant};
|
|
```
|
|
|
|
A small example:
|
|
|
|
```rust
|
|
use leptos::*;
|
|
use thaw::*;
|
|
|
|
fn main() {
|
|
mount_to_body(App);
|
|
}
|
|
|
|
#[component]
|
|
pub fn App() -> impl IntoView {
|
|
view! {
|
|
<Button variant=ButtonVariant::Primary>"Primary"</Button>
|
|
}
|
|
}
|
|
```
|