[package] description = "WebTransport IO layer implementation for `aeronet`" name = "aeronet_webtransport" authors.workspace = true categories.workspace = true edition.workspace = true keywords.workspace = true license.workspace = true repository.workspace = true rust-version.workspace = true version.workspace = true [lints] workspace = true [package.metadata.docs.rs] all-features = true rustflags = ["--cfg=web_sys_unstable_apis"] targets = ["x86_64-unknown-linux-gnu", "wasm32-unknown-unknown"] [features] default = ["self-signed"] ## Enables the `client` module. client = [] ## Enables the `server` module. server = [] ## Enables `wtransport/self-signed`, allowing you to generate self-signed certificates easily for ## use in a server. ## ## Note that, without explicitly allowing your server's self-signed certificate (or using ## `dangerous-configuration` and disabling certificate validation), clients will not be able to ## connect to a server with self-signed certificates. self-signed = ["wtransport/self-signed"] ## Enables `wtransport/dangerous-configuration`, allowing you to use potentially dangerous ## certificate validation configurations. ## ## You should not use dangerous configurations in production builds of your app. dangerous-configuration = ["wtransport/dangerous-configuration"] ## Enable this when generating docs. document-features = ["dep:document-features"] [dependencies] aeronet_io = { workspace = true } anyhow = { workspace = true } base64 = { workspace = true } bytes = { workspace = true } cfg-if = { workspace = true } derive_more = { workspace = true, features = ["display", "error", "from"] } futures = { workspace = true } replace_with = { workspace = true } tracing = { workspace = true } web-time = { workspace = true } xwt-core = { workspace = true } bevy_app = { workspace = true } bevy_ecs = { workspace = true } bevy_hierarchy = { workspace = true } bevy_reflect = { workspace = true } document-features = { workspace = true, optional = true } [target.'cfg(target_family = "wasm")'.dependencies] gloo-timers = { workspace = true, features = ["futures"] } js-sys = { workspace = true } wasm-bindgen = { workspace = true } wasm-bindgen-futures = { workspace = true } xwt-web-sys = { workspace = true } [target.'cfg(not(target_family = "wasm"))'.dependencies] spki = { workspace = true, features = ["fingerprint"] } tokio = { workspace = true, features = ["rt-multi-thread"] } wtransport = { workspace = true } x509-cert = { workspace = true } xwt-wtransport = { workspace = true } [dev-dependencies] bevy = { workspace = true } bevy_egui = { workspace = true } [[example]] name = "webtransport_client" path = "examples/webtransport_client.rs" required-features = ["client"] [[example]] name = "webtransport_echo_server" path = "examples/webtransport_echo_server.rs" required-features = ["server", "self-signed"]