JavaScript UI Libraries & Blazor Components Suite – Smart UI › Forums › ComboBox › Filter by Ajax Calls › Reply To: Filter by Ajax Calls
February 15, 2023 at 5:41 pm
#104402
Participant
Hi Andrea,
Since ajax calls are asynchronous, the component will always load before receiving the response from the ajax call. They will load at the same time only if dataSource is a static array.
If dataSource is set to a function, like in the example I shared, it should be set in the ngAfterViewInit() function.
Best regards,
Ivan Peevski
Smart UI Team
https://www.htmlelements.com/