react-select icon indicating copy to clipboard operation
react-select copied to clipboard

Allow validation/rejection of options for allowCreate

Open asazernik opened this issue 10 years ago • 3 comments

It would be nice to be able to restrict the inputs that a user can attempt to create in "tags mode" - either by allowing newOptionCreator to reject a proposed value, or by allowing the text input itself to reject values as they're being typed in.

asazernik avatar Jan 14 '16 22:01 asazernik

+1

Shnolik avatar Mar 17 '16 10:03 Shnolik

By the way, I believe PR #1187 should resolve this issue. Please feel free top give the branch a spin and let me know if you have any concerns or other feedback. 😄

bvaughn avatar Sep 03 '16 03:09 bvaughn

This issue no longer exists in the 1.x code (as of PR #1187) and so I'm going to close it!

The new Creatable HOC supports a configurable isValidNewOption property that allows users to do custom validation on options. Learn more here.

Look for an updated RC with this functionality soon. 😎

bvaughn avatar Sep 04 '16 02:09 bvaughn