Inline package.json config of a workspace package is not read
The inline package.json config pass (process_package_json_inline_configs in crates/core/src/plugins/registry/mod.rs) reads only the root package.json. A plugin key in the manifest of a workspace package is ignored, for every plugin with a package_json_config_key (prettier, jest, babel, stylelint, ...).
Reproduction: a workspace apps/web/package.json with
{
"devDependencies": { "@acme/config-stylelint": "^1.0.0", "stylelint": "^16.0.0" },
"stylelint": { "extends": "@acme/config-stylelint" }
}
fallow dead-code reports @acme/config-stylelint as an unused devDependency of apps/web. The same key in the root package.json credits the package.
Expected: the workspace run applies the inline config pass to the manifest of each workspace package, as the root run does.
This is in v3.43.0 (npm install [email protected]).
fallow dead-code now reads the inline tool config of a workspace package.json. A key such as "prettier": "@acme/config-prettier" credits the package that it names, so fallow no longer reports that package as an unused dependency.
Thanks for the report and for the patch in #4527, @stanlrt.