mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-11-23 02:10:12 +01:00
Add ESLint rule forbidding extraneous defaultProps (#7453)
This commit is contained in:
parent
a271e7f456
commit
659b4360bc
@ -149,6 +149,7 @@
|
|||||||
"padded-blocks": "off",
|
"padded-blocks": "off",
|
||||||
"quotes": [2, "single", {"avoidEscape": true, "allowTemplateLiterals": true}],
|
"quotes": [2, "single", {"avoidEscape": true, "allowTemplateLiterals": true}],
|
||||||
"react/no-deprecated": 0,
|
"react/no-deprecated": 0,
|
||||||
|
"react/default-props-match-prop-types": 2,
|
||||||
"semi": [2, "never"],
|
"semi": [2, "never"],
|
||||||
"semi-spacing": [2, { "before": false, "after": true }],
|
"semi-spacing": [2, { "before": false, "after": true }],
|
||||||
"space-before-blocks": [2, "always"],
|
"space-before-blocks": [2, "always"],
|
||||||
|
@ -4,8 +4,6 @@ const h = require('react-hyperscript')
|
|||||||
const MenuDroppo = require('../../menu-droppo')
|
const MenuDroppo = require('../../menu-droppo')
|
||||||
const extend = require('xtend')
|
const extend = require('xtend')
|
||||||
|
|
||||||
const noop = () => {}
|
|
||||||
|
|
||||||
class Dropdown extends Component {
|
class Dropdown extends Component {
|
||||||
render () {
|
render () {
|
||||||
const {
|
const {
|
||||||
@ -55,8 +53,6 @@ class Dropdown extends Component {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Dropdown.defaultProps = {
|
Dropdown.defaultProps = {
|
||||||
isOpen: false,
|
|
||||||
onClick: noop,
|
|
||||||
useCssTransition: false,
|
useCssTransition: false,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -7,7 +7,6 @@ export default class Tooltip extends PureComponent {
|
|||||||
arrow: true,
|
arrow: true,
|
||||||
children: null,
|
children: null,
|
||||||
containerClassName: '',
|
containerClassName: '',
|
||||||
hideOnClick: false,
|
|
||||||
html: null,
|
html: null,
|
||||||
onHidden: null,
|
onHidden: null,
|
||||||
position: 'left',
|
position: 'left',
|
||||||
|
@ -25,7 +25,6 @@ class DraggableSeed extends Component {
|
|||||||
|
|
||||||
static defaultProps = {
|
static defaultProps = {
|
||||||
className: '',
|
className: '',
|
||||||
onClick () {},
|
|
||||||
}
|
}
|
||||||
|
|
||||||
componentWillReceiveProps (nextProps) {
|
componentWillReceiveProps (nextProps) {
|
||||||
|
Loading…
Reference in New Issue
Block a user