Skip to content

Nested ArrowFunctionExpression false negatives at v30.0.2 #656

@raineorshine

Description

@raineorshine

After upgrading to v30 v30.0.2, I am getting false negatives (linter was passing before) on nested ArrowFunctionExpressions.

e.g.

// FALSE NEGATIVE: previously bar did NOT require a JSDOC with my configuration
const foo = {
  bar: () => {
    ...
  }
}

// an arrow function assigned to a `const` correctly requires a JSDOC
const moo: () => {
  ...
}

Here is my rule configuration:

    "jsdoc/require-jsdoc": [
      2,
      {
        "require": {
          "ArrowFunctionExpression": true,
          "ClassDeclaration": true,
          "ClassExpression": true
        }
      }
    ]

I've read the changelog for v30 but I am not able to connect the description of breaking changes to the above issue. Neither removing ArrowFunctionExpression nor setting publicOnly fixes it. Thanks for your help!

My typescript version is ahead of the eslint parser, but it works fine on eslint-plugin-jsdoc v29.

    "eslint": "^7.14.0",
    "typescript": "4.0.5",
    "@typescript-eslint/eslint-plugin": "^3.10.1",
    "@typescript-eslint/parser": "^3.10.1",

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions