Re-enable rule prefer-destructuring (only for objects) (#10867)

This commit is contained in:
Kamil Gabryjelski
2020-09-14 19:11:20 +02:00
committed by GitHub
parent c51168a30a
commit 352e8a1afd
53 changed files with 80 additions and 83 deletions

View File

@@ -57,8 +57,7 @@ export default class EmbedCodeButton extends React.Component {
}
handleInputChange(e) {
const value = e.currentTarget.value;
const name = e.currentTarget.name;
const { value, name } = e.currentTarget;
const data = {};
data[name] = value;
this.setState(data);