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

"require-optimization" shouldn't warn on stateless components #687

Closed
nkt opened this issue Jul 18, 2016 · 1 comment
Closed

"require-optimization" shouldn't warn on stateless components #687

nkt opened this issue Jul 18, 2016 · 1 comment
Labels

Comments

@nkt
Copy link

nkt commented Jul 18, 2016

Configuration:

"rules": {
  "react/require-optimization": 2
}

Code:

import React from 'react';
import styles from './Spinner.css';

function Spinner() { // Component is not optimized. Please add a shouldComponentUpdate method
  return <div className={styles.spinner} />;
}

export default Spinner;
@nkt
Copy link
Author

nkt commented Jul 26, 2016

Great, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

No branches or pull requests

2 participants