Skip to main content

description-type

Enabling this rule will result in an error being generated if the value in description is not a string.

Example .npmpackagejsonlintrc configuration

{
"rules": {
"description-type": "error"
}
}

Rule Details

Incorrect example(s)

{
"description": 1
}
{
"description": ["CLI app for linting package.json files."]
}
{
"description": {
"summary": "CLI app for linting package.json files."
}
}

Correct example(s)

{
"description": "CLI app for linting package.json files."
}

History

  • Introduced in version 0.1.0