reasonml / reason-react

Reason bindings for ReactJS
https://reasonml.github.io/reason-react/
MIT License
3.25k stars 347 forks source link

`ReactEvent` -> `React.Event` in docs #831

Open benbellick opened 5 months ago

benbellick commented 5 months ago

It seems a lot of places in the docs say ReactEvent, when they mean to say React.Event, e.g.:

/* App.re */
/* CORRECT! This code is bug-free. 👍 */
[@react.component]
let make = () => {
  let (name, setName) = React.useState(() => "John");
  <input
    type_="text"
    value={name}
    onChange={
      event => {
        let value = ReactEvent.Form.target(event)##value;
        setName(_ => value)
      }
    }
  />;
};
benbellick commented 5 months ago

Happy to fix this one myself, but just wanted to get it down before I forget!

davesnx commented 5 months ago

Good catch, I forgot to update the docs references with the last update.