react-autoselect

1.0.2 • Public • Published

react-autoselect

Select-on-focus fields for ReactJS.

import React from 'react'
import {render} from 'react-dom'
import {Input, TextArea} from 'react-autoselect'

render(
  <div>
    <Input type="text" width="200" />
    <TextArea rows="3" />
  </div>,
  document.getElementById('app')
)

Custom onFocus, including cancelling the select by returning false or preventing default:

<Input onFocus={() => console.log('focus')} />
<Input onFocus={() => false} />
<Input onFocus={(e) => e.preventDefault()} />

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.0.2
    0
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 1.0.2
    0
  • 1.0.1
    6
  • 1.0.0
    0

Package Sidebar

Install

npm i react-autoselect

Weekly Downloads

6

Version

1.0.2

License

ISC

Unpacked Size

791 kB

Total Files

9

Last publish

Collaborators

  • adjohnson916