Cargo Features

[dependencies]
rspack_resolver = { version = "0.4.1", default-features = false, features = ["package_json_raw_json_api", "yarn_pnp", "codspeed", "document-features"] }
default = yarn_pnp

The yarn_pnp feature is set by default whenever rspack_resolver is added without default-features = false somewhere in the dependency tree.

package_json_raw_json_api

Enables the PackageJson::raw_json API, which returns the package.json with serde_json::Value.

yarn_pnp default = pnp

Yarn Plug'n'Play

Affects file_system::FileSystemOptions.enable_pnp, options::ResolveOptions.enable_pnp

codspeed dev

For codspeed benchmark

Enables codspeed of criterion2 ^1.0.0

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.

pnp yarn_pnp
document-features implicit feature

Enables document-features

document-features:

Extract documentation for the feature flags from comments in Cargo.toml