Cargo Features
[dependencies]
zync-core = { version = "0.2.0", default-features = false, features = ["client", "parallel", "wasm", "wasm-parallel"] }
- default = client, parallel
-
These default features are set whenever
zync-coreis added withoutsomewhere in the dependency tree.default-features = false - client default = prost, tokio, tokio-stream, tonic, tracing
-
Affects
client::zidecar_proto,client::lightwalletd_proto,zync-core::client… - parallel default wasm-parallel? = rayon
- wasm wasm-parallel? = console_error_panic_hook, wasm-bindgen
-
WASM support (single-threaded, but with wasm-bindgen for JS interop)
Enables js of getrandom ^0.2
Affects
scanner::wasm_init… - wasm-parallel = js-sys, parallel, wasm, wasm-bindgen-rayon
-
Multi-threaded WASM (requires SharedArrayBuffer + CORS headers)
Affects
scanner::init_thread_pool…
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.
- tonic client
-
Enables tonic ^0.11
gRPC client (optional)
- prost client
-
Enables prost ^0.12
- tokio client
- tokio-stream client
- tracing client
- rayon parallel
-
Enables rayon
parallel scanning (native and WASM with wasm-bindgen-rayon)
- wasm-bindgen wasm?
-
Enables wasm-bindgen
WASM dependencies
- wasm-bindgen-rayon wasm-parallel?
- console_error_panic_hook wasm?
- getrandom wasm?
-
Enables getrandom ^0.2
- js-sys wasm-parallel?