Open
Description
I'm dynamically creating options for dropdown.
Once all options generated I'm using $("#teamMember").trigger("chosen:updated") to build dropdown.
I have tried $("#teamMember").chosen({max_selected_options: 3}); before and after $("#teamMember").trigger("chosen:updated") but it does not restrict Max selection not it trigger $("#teammember").bind("chosen:maxselected", function (evt, params) {});
Code:
uniqueGroupUsers.forEach((user) => {
$('#teamMember').append($('', {
value: user.Email,
text: user.Title
}));
});
$("#teamMember").chosen({max_selected_options: 3});
$("#teamMember").trigger("chosen:updated");
Metadata
Assignees
Labels
No labels