You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Every element inside the .toclone element gets its id updated properly with incremental ids. However, the id of the main .toclone element itself doesn't.
Say, if you use bootstrap tabs where every tabpanel requires an id to have it working properly, you'll probably end up with something like this:
Clone this once, the tabpanel gets id tab1. Clone it twice from the same tabpanel, you'll end up with tab1 and tab2. So far so good.
However, if you decide to clone from the tabpanel with id tab1, the cloned tabpanel will have its id set to tab11.
Basically, the ids don't get replaced and only get added. After messing around with this enough, you may end up with tab1113411231 instead of tab6 for example.
The text was updated successfully, but these errors were encountered:
but it's still a unique identifier, right? That's all the functionality offers. Trying to maintain a sequential list of cloned objects when users can clone and delete objects would be considerably more complex.
Every element inside the
.toclone
element gets its id updated properly with incremental ids. However, the id of the main.toclone
element itself doesn't.Say, if you use bootstrap tabs where every tabpanel requires an id to have it working properly, you'll probably end up with something like this:
Clone this once, the tabpanel gets id
tab1
. Clone it twice from the same tabpanel, you'll end up withtab1
andtab2
. So far so good.However, if you decide to clone from the tabpanel with id
tab1
, the cloned tabpanel will have its id set totab11
.Basically, the ids don't get replaced and only get added. After messing around with this enough, you may end up with
tab1113411231
instead oftab6
for example.The text was updated successfully, but these errors were encountered: