dioxus/packages/router/Cargo.toml
Evan Almloff 0127501dbf
Improve inline docs (#2460)
Improve inline docs

* improve incorrect event handler return error message

* Improve event handler docs

* document the eval functions

* document spawn and common spawn errors

* fix event handler docs

* add notes about how you use attributes and elements in rsx

* add doc aliases for attributes and events we rename

* add some more aliases for common search terms

* don't doc ignore any public examples in core

* don't ignore public doc examples in ssr

* don't ignore examples in the dioxus package readme

* add a warning when you launch without a renderer enabled

* fix some outdated element docs

* add a bunch of examples to resource

* add notes about desktop events

* add more docs for use_resource

* add on_unimplemented hint to Dependency

* fix some unresolved links

* add examples to each of the router traits

* add not implemented errors for router traits

* add an example to the routable trait

* expand rsx macro docs

* improve memo docs

* update the dioxus readme

* mention dioxus crate features in the docs

* fix a bunch of doc tests

* fix html doc tests

* fix router doc tests

* fix dioxus signals doc tests

* fix dioxus ssr doc tests

* fix use_future example in the hooks cheat sheet

* add a javascript alias for eval

* fix hook explanation values

* remove unused embed-doc-image dependency
2024-06-06 18:15:17 -07:00

108 lines
3.3 KiB
TOML

[package]
name = "dioxus-router"
authors = ["Jonathan Kelley", "Evan Almloff"]
version = { workspace = true }
edition = "2021"
description = "Cross-platform router for Dioxus apps"
license = "MIT OR Apache-2.0"
repository = "https://github.com/DioxusLabs/dioxus/"
homepage = "https://dioxuslabs.com"
keywords = ["dom", "ui", "gui", "react", "wasm"]
[dependencies]
dioxus-lib = { workspace = true }
dioxus-router-macro = { workspace = true }
gloo = { version = "0.8.0", optional = true }
tracing = { workspace = true }
urlencoding = "2.1.3"
serde = { version = "1", features = ["derive"], optional = true }
serde_json = { version = "1.0.91", optional = true }
url = "2.3.1"
wasm-bindgen = { workspace = true, optional = true }
web-sys = { version = "0.3.60", optional = true, features = [
"ScrollRestoration",
] }
js-sys = { version = "0.3.63", optional = true }
gloo-utils = { version = "0.1.6", optional = true }
dioxus-liveview = { workspace = true, optional = true }
dioxus-ssr = { workspace = true, optional = true }
http = { workspace = true, optional = true }
dioxus-fullstack = { workspace = true, optional = true }
tokio = { workspace = true, features = ["full"], optional = true }
dioxus-cli-config = { workspace = true, features = ["read-config"] }
rustversion = "1.0.17"
# you need to comment this out when publishing since cargo workspaces is not smart enough to wipe this when dropping
# dev-dependncey crates
[target.'cfg(target_family = "wasm")'.dev-dependencies]
console_error_panic_hook = "0.1.7"
dioxus-router = { workspace = true, features = ["web"] }
# dioxus-web = { workspace = true }
gloo = "0.8.0"
wasm-bindgen-test = "0.3.33"
[features]
default = []
ssr = ["dioxus-ssr/incremental", "tokio", "dioxus-fullstack?/server", "http"]
liveview = ["dioxus-liveview", "tokio", "dep:serde", "serde_json"]
wasm_test = []
web = ["gloo", "web-sys", "wasm-bindgen", "gloo-utils", "js-sys", "dioxus-router-macro/web"]
fullstack = ["dioxus-fullstack"]
[dev-dependencies]
axum = { workspace = true, features = ["ws"] }
dioxus = { workspace = true, features = ["router"] }
dioxus-ssr = { workspace = true }
criterion = { version = "0.5", features = ["async_tokio", "html_reports"] }
ciborium = { version = "0.2.1" }
base64 = { version = "0.21.0" }
serde = { version = "1", features = ["derive"] }
[package.metadata.docs.rs]
cargo-args = ["-Zunstable-options", "-Zrustdoc-scrape-examples"]
[[bench]]
name = "incremental"
required-features = ["ssr"]
harness = false
# Most of the examples live in the workspace. We include some here so that docs.rs can scrape our examples for better inline docs
[[example]]
name = "crm"
path = "../../examples/crm.rs"
doc-scrape-examples = true
[[example]]
name = "flat_router"
path = "../../examples/flat_router.rs"
doc-scrape-examples = true
[[example]]
name = "hash_fragment_state"
path = "../../examples/hash_fragment_state.rs"
doc-scrape-examples = true
[[example]]
name = "link"
path = "../../examples/link.rs"
doc-scrape-examples = true
[[example]]
name = "query_segment_search"
path = "../../examples/query_segment_search.rs"
doc-scrape-examples = true
[[example]]
name = "router"
path = "../../examples/router.rs"
doc-scrape-examples = true
[[example]]
name = "simple_router"
path = "../../examples/simple_router.rs"
doc-scrape-examples = true
[[example]]
name = "static_generation"
required-features = ["ssr"]
doc-scrape-examples = true