valid-bundleDependencies
💼 This rule is enabled in the following configs: ✅ recommended, 📦 recommended-publishable.
This rule uses package-json-validator to validate the bundleDependencies property (as well as its alias bundledDependencies) in a package.json against the following criteria:
- It must be either an array or a boolean.
- If the value is an Array, it should only consist of non-empty strings.
Example of incorrect code for this rule:
Example of correct code for this rule:
Examples
Section titled “Examples”{ "bundleDependencies": { "some-dependency": "^1.0.0" }}{ "bundleDependencies": ["some-dependency"]}{ "bundleDependencies": true}Related Rules
Section titled “Related Rules”require-bundleDependencies- Enforces that thebundleDependenciesproperty is present.