mirror of
https://github.com/yewstack/yew.git
synced 2025-12-08 21:26:25 +00:00
Less error prone yew-router instructions (#3552)
Simply add yew-router via cargo and hope that cargo figures out the correct version. For most users referencing git directly is wrong and might lead to annoying errors when compiling. Before, there was even a comment to keep the version reference up-to-date which obviously did not work and seems unpractical.
This commit is contained in:
parent
3a51a03c8b
commit
1e62f1e7c8
@ -8,12 +8,10 @@ default behavior of requesting a different remote resource when a link is clicke
|
||||
locally to point to a valid route in your application. The router then detects this change and then decides what to
|
||||
render.
|
||||
|
||||
Yew provides router support in the `yew-router` crate. To start using it, add the dependency to your `Cargo.toml`
|
||||
Yew provides router support in the `yew-router` crate. To start using it, add the dependency to your `Cargo.toml`:
|
||||
|
||||
<!-- Reminder: fix this when we release a new version of yew -->
|
||||
|
||||
```toml
|
||||
yew-router = { git = "https://github.com/yewstack/yew.git" }
|
||||
```sh
|
||||
cargo add yew-router
|
||||
```
|
||||
|
||||
The utilities needed are provided under `yew_router::prelude`,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user