SHARE
TWEET

Untitled

a guest Jan 22nd, 2020 63 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Что происходит в текущем коде и как его можно улучшить?
  2. 1. updateState = () => this.state.imRambo = true;
  3. 2. users.map((user) => (<UserComponent {...user} />));
  4. 3.
  5. class MyComponent extends React.Component {
  6.     state = {
  7.         counter: 1,
  8.     };
  9.     incrementCounter = () => this.setState({ counter: this.state.counter + 1 });
  10.     massIncrement = () => {
  11.         this.incrementCounter();
  12.         this.incrementCounter();
  13.     }
  14. }
  15. 4. class MyComponent extends React.Component {
  16.       constructor(props) {
  17.         this.state = {ok: 200};
  18.       }
  19.    }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top