Cargo Features

[dependencies]
flutter_rust_bridge = { version = "2.6.0", default-features = false, features = ["backtrace", "chrono", "dart-opaque", "portable-atomic", "rust-async", "thread-pool", "user-utils", "uuid", "wasm-start", "anyhow", "log"] }
default = anyhow, dart-opaque, log, portable-atomic, rust-async, thread-pool, user-utils, wasm-start

These default features are set whenever flutter_rust_bridge is added without default-features = false somewhere in the dependency tree.

backtrace

Enables allo-isolate and backtrace

chrono

Enables chrono, chrono of allo-isolate

Affects manual_impl::decode_timestamp, manual_impl::Timestamp

dart-opaque default

Enables dart-sys-fork

Affects misc_rust_async::convert_into_dart_fn_future, handler::Handler.dart_fn_invoke, handler::Handler.dart_fn_handle_output

portable-atomic default

Enables portable-atomic

rust-async default

Enables futures, tokio, and wasm-bindgen-futures

Affects executor::Executor.execute_async, handler::Handler.wrap_async, misc_rust_async::convert_into_dart_fn_future, handler::Handler.dart_fn_invoke, handler::Handler.dart_fn_handle_output

thread-pool default

Enables threadpool

Affects executor::Executor.execute_normal, handler::Handler.wrap_normal, web::spawn_blocking_with

user-utils default

Enables android_logger ^0.13 and oslog ^0.1.0

uuid

Enables uuid, uuid of allo-isolate

Affects manual_impl::decode_uuid

wasm-start default = console_error_panic_hook

Affects web::wasm_start_callback

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.

anyhow default
log default
console_error_panic_hook wasm wasm-start