Skip to content
This repository has been archived by the owner on Jul 19, 2023. It is now read-only.

ahrefs/bs-react-select

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

67 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Warning This repository is no longer maintained, as we don't use it anymore at Ahrefs.

Reason bindings for react-select

Reason bindings for react-select.

Status

🚧 Not everything is supported yet; Unstable; Doesn't follow semver; 🚧

Feel free to create an issue or PR.

Installation, npm

npm install --save @ahrefs/bs-react-select

Then add @ahrefs/bs-react-select to bs-dependencies in your bsconfig.json:

{
  ...
  "bs-dependencies": ["@ahrefs/bs-react-select"]
}

To include styles

[%bs.raw {|require('react-select/dist/react-select.css')|}];

Contributing/Development

Run yarn start for bucklescript compiler watcher. Then run yarn start:reshowcase which will start on localhost:9001.

It would be good to have an example for every component and every prop eventually.

TODO

  • aria-describedby / aria-label / aria-labelledby SpecialCreationFunction doesn't allow to change prop name, hopefully this will be possible in the next bucklescript releases
  • Annotate Async props
  • Annotate Creatable props
  • Can we reduce boilerplate in Select.re and SelectMulti.re?
  • Upgrade to react-select version 2
  • resetValue / value - string | 'a OR string | array('a)
  • filterOptions - bool | func
  • Separate SelectMulti

Examples

TODO

Select vs SelectMulti

  • Option.arg - Val vs Arr
  • onChange - option('a) vs array('a)
  • onValueClick - 'a vs array('a)
  • filterOptions - one extra argument ~current: array('a)

About

ReasonML bindings for react-select

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published