[DOC] doc: remove references to updateState

This commit is contained in:
Géry Debongnie
2019-04-17 10:57:49 +02:00
parent ce87dd705e
commit 7a479baf63
2 changed files with 1 additions and 7 deletions
+1 -4
View File
@@ -16,7 +16,7 @@ export class Counter extends Component {
}
increment(delta) {
this.updateState({ counter: this.state.counter + delta });
this.state.counter += delta;
}
}
```
@@ -88,9 +88,6 @@ It is not called on the initial render. This is useful to get some
information which are in the DOM. For example, the current position of the
scrollbar
Note that at this point, it is not safe to rerender the widget. In
particular, updateState calls should be avoided.
### patched
This hook is called whenever a component did actually update its props,
-3
View File
@@ -168,9 +168,6 @@ export class Component<
* It is not called on the initial render. This is useful to get some
* information which are in the DOM. For example, the current position of the
* scrollbar
*
* Note that at this point, it is not safe to rerender the widget. In
* particular, updateState calls should be avoided.
*/
willPatch() {}