react-input-fixer

Provides a workaround for phantom blur/focus events for HTML inputs in Safari MacOS.

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
react-input-fixer
201.0.36 years ago6 years agoMinified + gzip package size for react-input-fixer in KB

Readme

react-input-fixer for React
npm version
Provides a workaround for phantom blur/focus events for HTML inputs in Safari MacOS. The bug this code fixes is described in a WebKit bug/Radar and React bug.
For details of the original problem and code, see the Vanilla JS version.

Usage

The <FixedInput ... /> directly replaces a regular <input ... /> and fixes Safari's event mangling.
import FixedInput from './FixedInput'

…
  render() {
    return <FixedInput ... />
  }
…