/react-tiny-form

[react-tiny-form]

Primary LanguageJavaScript

react-tiny-form

  • Textarea

    • onChange(value, event)
  • Input

    • onChange(value, event)
  • Checkbox

    • onChange(checked, event)
  • Radio

    • onChange(checked, event)
  • Link

    • just tag a, with default props: target='_blank' rel='noopener noreferrer'
  • Select

    const options = [{
      name: 'one',
      id: 1
    }, {
      name: 'two',
      id: 2
    }, {
      name: 'three',
      id: 3
    }]
    <Select options={options} optLabel='name' optValue='id'
      value={opt.id} onChange={opt => this.setState({opt})} />

License

MIT