Skip to content

fundingValidity

Enforces that the funding property is valid.

✅ This rule is included in the package-json logical presets.

This rule checks that the funding property is a URL string, a funding object, or an array of URL strings and funding objects. Funding objects should have non-empty type and url properties.

{
"funding": "not-a-url"
}
{
"funding": {
"type": "individual"
}
}

If you don’t need compliance with npm’s funding field specification, you can disable this rule. For example, if your package registry accepts a different funding metadata shape, this rule may not be correct for you.

Made with ❤️‍🔥 around the world by the Flint team and contributors.