datastar 0.4.0

Datastar SDK for Rust
Documentation
# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2024"
rust-version = "1.89.0"
name = "datastar"
version = "0.4.0"
authors = [
    "Johnathan Stevers <jmstevers@gmail.com>",
    "Glen Henri J. De Cauwsemaecker <glen@plabayo.tech>",
]
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Datastar SDK for Rust"
homepage = "https://data-star.dev"
documentation = "https://docs.rs/datastar"
readme = "README.md"
keywords = [
    "datastar",
    "backend",
    "axum",
    "rocket",
    "warp",
]
categories = ["web-programming"]
license = "MIT"
repository = "https://github.com/starfederation/datastar-rust"

[package.metadata.docs.rs]
all-features = true
rustdoc-args = [
    "--cfg",
    "docsrs",
]

[features]
axum = [
    "dep:axum",
    "dep:serde",
    "dep:serde_json",
]
rocket = [
    "dep:rocket",
    "rocket/json",
]
tracing = ["dep:tracing"]
warp = [
    "dep:warp",
    "dep:serde",
    "dep:serde_json",
    "dep:serde_urlencoded",
    "dep:bytes",
]

[lib]
name = "datastar"
path = "src/lib.rs"

[[example]]
name = "axum-activity-feed"
path = "examples/axum-activity-feed.rs"
required-features = [
    "axum",
    "tracing",
]

[[example]]
name = "axum-hello"
path = "examples/axum-hello.rs"
required-features = [
    "axum",
    "tracing",
]

[[example]]
name = "axum-live-reload"
path = "examples/axum-live-reload.rs"
required-features = [
    "axum",
    "tracing",
]

[[example]]
name = "axum-test-suite"
path = "examples/axum-test-suite.rs"
required-features = [
    "axum",
    "tracing",
]

[[example]]
name = "axum-watch"
path = "examples/axum-watch.rs"
required-features = ["axum"]

[[example]]
name = "rocket-hello"
path = "examples/rocket-hello.rs"
required-features = ["rocket"]

[[example]]
name = "rocket-hello-channel"
path = "examples/rocket-hello-channel.rs"
required-features = ["rocket"]

[[example]]
name = "rocket-test-suite"
path = "examples/rocket-test-suite.rs"
required-features = ["rocket"]

[[example]]
name = "warp-activity-feed"
path = "examples/warp-activity-feed.rs"
required-features = [
    "warp",
    "tracing",
]

[[example]]
name = "warp-hello"
path = "examples/warp-hello.rs"
required-features = [
    "warp",
    "tracing",
]

[[example]]
name = "warp-test-suite"
path = "examples/warp-test-suite.rs"
required-features = [
    "warp",
    "tracing",
]

[dependencies.axum]
version = "0.8.5"
features = [
    "query",
    "json",
]
optional = true
default-features = false

[dependencies.bytes]
version = "1"
optional = true
default-features = false

[dependencies.rocket]
version = "0.5"
optional = true
default-features = false

[dependencies.serde]
version = "1"
features = ["derive"]
optional = true
default-features = false

[dependencies.serde_json]
version = "1"
features = ["std"]
optional = true
default-features = false

[dependencies.serde_urlencoded]
version = "0.7"
optional = true
default-features = false

[dependencies.tracing]
version = "0.1"
features = ["std"]
optional = true
default-features = false

[dependencies.warp]
version = "0.4"
optional = true
default-features = false

[dev-dependencies.asynk-strim]
version = "0.1"

[dev-dependencies.axum]
version = "0.8.5"
features = [
    "http1",
    "tokio",
]
default-features = false

[dev-dependencies.chrono]
version = "0.4"
features = ["clock"]
default-features = false

[dev-dependencies.indexmap]
version = "2.11"
features = [
    "serde",
    "std",
]
default-features = false

[dev-dependencies.rocket]
version = "0.5"
default-features = false

[dev-dependencies.serde]
version = "1"
features = ["derive"]
default-features = false

[dev-dependencies.serde_json]
version = "1"
features = ["std"]
default-features = false

[dev-dependencies.tokio]
version = "1"
features = [
    "macros",
    "net",
    "rt-multi-thread",
    "sync",
    "time",
]
default-features = false

[dev-dependencies.tokio-stream]
version = "0.1"
default-features = false

[dev-dependencies.tracing]
version = "0.1"
features = ["std"]
default-features = false

[dev-dependencies.tracing-subscriber]
version = "0.3"
features = [
    "env-filter",
    "fmt",
]
default-features = false

[dev-dependencies.warp]
version = "0.4"
features = ["test"]
default-features = false

[lints.clippy]
await_holding_lock = "warn"
empty_enums = "warn"
enum_glob_use = "warn"
exit = "warn"
filter_map_next = "warn"
fn_params_excessive_bools = "warn"
if_let_mutex = "warn"
imprecise_flops = "warn"
inefficient_to_string = "warn"
linkedlist = "warn"
lossy_float_literal = "warn"
macro_use_imports = "warn"
match_wildcard_for_single_variants = "warn"
mem_forget = "warn"
needless_borrow = "warn"
needless_continue = "warn"
option_option = "warn"
rest_pat_in_fully_bound_structs = "warn"
str_to_string = "warn"
suboptimal_flops = "warn"
todo = "warn"
type_complexity = "allow"
unnested_or_patterns = "warn"
unused_self = "warn"
verbose_file_reads = "warn"

[lints.clippy.all]
level = "warn"
priority = -1

[lints.rust]
elided_lifetimes_in_paths = "allow"
unreachable_pub = "deny"

[lints.rust.unexpected_cfgs]
level = "warn"
priority = 0
check-cfg = ["cfg(fuzzing)"]

[profile.dev]
opt-level = 1

[profile.dev.package."*"]
opt-level = 3

[profile.release]
lto = "thin"
codegen-units = 1