Closed masadi closed 2 years ago
@masadi do you mean optgroup ?
@MoamenEltouny like this http://jsfiddle.net/greglockwood/T7LJY/3
@masadi i don't think it's supported in Select2 Plugin at all .. but i believe that you can create it with livewire itself it's not related to our package
@MoamenEltouny here is another example using laravel 8 and ajax http://ilmukita.org/laravel-8-membuat-dynamic-dependent-dropdown-menggunakan-select2/
@MoamenEltouny SOLVED
window.addEventListener('component_updated', event => {
$.each(event.detail.data_array, function (i, item) {
$('#sub_select').append($('<option>', {
value: item.value,
text : item.text
}));
});
})
How to use this repo for nested dropdown like selecting province then city and so on?
Thanks