I need to use a DropDownList in React with this functionality.
By default, it will display the top 30 items loaded on the first page load. Then, I need to filter the rest with an Ajax call.
The problem is that when the dataSource is set to a callback, it always displays an empty DropDownList.
Example:
const topDiagnosis = [
{
value: 1,
label: ‘test a’
},
{
value: 2,
label: ‘test b’
},
];
const dataSourceCallback = function(query, response) {
console.log('dataSourceCallback', query, response)
return topDiagnosis;
};
<DropDownList
filterable
filterInputPlaceholder="Hledat"
dataSource={dataSourceCallback}
/>
Thank you
-
This topic was modified 3 months, 1 week ago by Ondřej.
-
This topic was modified 3 months, 1 week ago by Ondřej.
-
This topic was modified 3 months, 1 week ago by Ondřej.
-
This topic was modified 3 months, 1 week ago by Ondřej.