Specify default props

This commit is contained in:
Shin'ya Ueoka 2019-04-30 09:15:58 +09:00
parent 808344eecf
commit fce2434dcd
4 changed files with 8 additions and 19 deletions
src/settings/components/form

View file

@ -30,10 +30,6 @@ class KeymapsForm extends React.Component {
}
bindValue(e) {
if (!this.props.onChange) {
return;
}
let next = { ...this.props.value };
next[e.target.name] = e.target.value;
@ -48,6 +44,7 @@ KeymapsForm.propTypes = {
KeymapsForm.defaultProps = {
value: {},
onChange: () => {},
};
export default KeymapsForm;