Skip to content

valid-funding

💼 This rule is enabled in the following configs: ✅ recommended, 📦 recommended-publishable.

This rule uses package-json-validator to validate the funding property, if present, against the following criteria:

  • The value is an object, a string, or an Array of objects and strings
  • If it’s an object, it should have properties type and url
  • type should be a non-empty string
  • url should be a valid URL
  • If it’s a string, it should be a URL.
{
"funding": {
"email": "some@mail.com",
"type": "patreon"
}
}