Secondary initialize "mdb-select" is possible

MDB SupportCategory: MDB jQuerySecondary initialize "mdb-select" is possible
Boris Akimenko Pro User asked 2 weeks ago in MDB pro, version:4.5.3

Hi guys!
Secondary initialized  $(‘.mdb-select’).material_select(); gives multiple material view on already initialized selects.

So if I dynamically add some <select> element, then I have to get this element and initialize it instead just run $(‘.mdb-select’).material_select().

2 Answers
Mikołaj Smoleński answered 2 weeks ago

Hi Boris,

Can You try to give select a new class each time You add the next select? Then You can initialize only this select without changing the others.


Alex Gotardi Pro User answered 5 days ago



or destroy and create mdb-select, but’s more expensive to browser cpu-usage


// Material Select Destroy
Mikołaj Smoleński replied 5 days ago

Thanks for sharing Your solution!