You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Though there seems to be a bug, I added a "group" to the options prop on FacetedSelect and changed the behaviour of buildOptions() to:
// sort options by groupconstgroupedOptions=newMap();for(constoofoptions){constgroup=o.group||'Other';constoptionsForGroup=groupedOptions.get(group)||[];optionsForGroup.push({value: o.label,label: o.label,getSuggestions: o.getSuggestions});groupedOptions.set(group,optionsForGroup);}returnArray.from(groupedOptions).map(([key,value])=>{return{label: key,options: value}});
Resulting in:
Uncaught TypeError: Cannot read property 'toLowerCase' of undefined
at compareOption (Creatable.js:40)
at Creatable.js:51
at Array.some ()
at isValidNewOption (Creatable.js:50)
at Creatable.componentWillReceiveProps (Creatable.js:133)
at callComponentWillReceiveProps (react-dom.development.js:11528)
at updateClassInstance (react-dom.development.js:11720)
at updateClassComponent (react-dom.development.js:13154)
at beginWork (react-dom.development.js:13825)
at performUnitOfWork (react-dom.development.js:15864)
Follow example of react-select https://codesandbox.io/s/w6n5llr6kl?module=/example.js
Though there seems to be a bug, I added a "group" to the options prop on FacetedSelect and changed the behaviour of buildOptions() to:
Resulting in:
Uncaught TypeError: Cannot read property 'toLowerCase' of undefined
at compareOption (Creatable.js:40)
at Creatable.js:51
at Array.some ()
at isValidNewOption (Creatable.js:50)
at Creatable.componentWillReceiveProps (Creatable.js:133)
at callComponentWillReceiveProps (react-dom.development.js:11528)
at updateClassInstance (react-dom.development.js:11720)
at updateClassComponent (react-dom.development.js:13154)
at beginWork (react-dom.development.js:13825)
at performUnitOfWork (react-dom.development.js:15864)
Some related issues:
This feature can be implemented in a non-breaking way so its not urgent