-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
Parse explicit declaration that class extends React.Component #513
Parse explicit declaration that class extends React.Component #513
Conversation
@@ -25,6 +25,7 @@ | |||
"devDependencies": { | |||
"babel-eslint": "6.0.0-beta.6", | |||
"coveralls": "2.11.8", | |||
"doctrine": "^1.2.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this would need to be a full dependency
since it's not related to actually developing the module.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Whoops! Quite right.
On 25 Mar 2016 01:46, "Jordan Harband" notifications@github.com wrote:
In package.json
#513 (comment)
:@@ -25,6 +25,7 @@
"devDependencies": {
"babel-eslint": "6.0.0-beta.6",
"coveralls": "2.11.8",
- "doctrine": "^1.2.0",
this would need to be a full dependency since it's not related to
actually developing the module.—
You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub
https://github.com/yannickcr/eslint-plugin-react/pull/513/files/f3e634c59e8928ab170a9bfa9d056cf0f8778064#r57411882
Merged, thanks! |
I wonder if we should make doctrine an optionalDependency, so people that don't use jsdoc don't need to install it? |
I don't like adding a dependency either. But since this dependency is already used by ESLint I think it will already be installed in all cases (it will even be deduplicated with npm@3). |
An, makes sense |
This small addition enables linting component-specific rules if the author uses a JSDoc explicitly indicating that the component is a descendent of React.Component
e.g.
Provides a good workaround for issues such as #68