@samitouri / QOS-React-2 / commits / ae83e90ec7

[#3964] Add note about React's onChange vs. DOM's oninput

Andreas Savvides committed Jun 2, 2015 at 14:47 UTC ae83e90ec758bd7311a1052dbc58a308edb90d46
1 file changed +4
docs/docs/07-forms.md
+4
@@ -28,6 +28,10 @@ Form components allow listening for changes by setting a callback to the `onChan
28
29 Like all DOM events, the `onChange` prop is supported on all native components and can be used to listen to bubbled change events.
30
31 +> Note:
32 +>
33 +> For `<input>` and `<textarea>`, `onChange` supersedes — and should generally be used instead of — the DOM's built-in [`oninput`](https://developer.mozilla.org/en-US/docs/Web/API/GlobalEventHandlers/oninput) event handler.
34 +
35
36 ## Controlled Components
37