Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

For deprecated lifecycle methods, report identifier AST node instead of the class node #1854

Merged
merged 3 commits into from Jun 28, 2018

Commits on Jun 26, 2018

  1. For deprecated lifecycle methods, report identifier node instead of t…

    …he class node
    
    When the `no-deprecated` rule finds a deprecated lifecycle method, it reports the whole
    class declaration as the AST node for the error. Doesn't look good in editor and hides all
    other ESLint errors inside the class.
    
    This patch changes the reported AST node to the method name identifier. The errors are
    much better targeted at the infringing code and look much better when shown in editor UI.
    
    Added also test coverage to check for the reported AST node type.
    jsnajdr committed Jun 26, 2018
    Copy the full SHA
    c4cef42 View commit details
    Browse the repository at this point in the history
  2. Copy the full SHA
    a5ded4d View commit details
    Browse the repository at this point in the history
  3. Copy the full SHA
    248c2ca View commit details
    Browse the repository at this point in the history