Cargo Features

[dependencies]
node-html-parser = { version = "0.1.0", default-features = false, features = ["parallel", "wasm", "serde"] }
default = parallel

The parallel feature is set by default whenever node-html-parser is added without default-features = false somewhere in the dependency tree.

parallel default = rayon
wasm = console_error_panic_hook, wasm-bindgen

wasm feature: disable rayon usage by not enabling parallel, add wasm related helpers

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.

wasm-bindgen wasm?
rayon parallel

Enables rayon

rayon 放到可选

console_error_panic_hook wasm?
serde implicit feature

Enables serde

serde:

A generic serialization/deserialization framework