React Bootstrap: FormControl textbox Example

For whatever reason, React Bootstrap has gotten rid of Input tags, and you will get deprecation warnings if you use them.

The new, new way, is to use FormControls, which you can use to do the same thing:

<FormGroup>
  <FormControl
    type="text"
    value={query}
    id="searchButton"
    ref="input"
    className="searchButton"
    onKeyUp={onKeyUp}
    onChange={onChangeSearch}
    buttonAfter={searchActions}
    placeholder="Search..." />
  </FormGroup>

If you want a good Javascript book, I got a lot out of Secrets of the Javascript Ninja.

0 replies

Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply

Your email address will not be published. Required fields are marked *