[v5][doc] or [dropdown] show class applied to element
Created by: piernik
Doc's says: https://v5.getbootstrap.com/docs/5.0/components/dropdowns/#usage
Via data attributes or JavaScript, the dropdown plugin toggles hidden content (dropdown menus) by toggling the .show class on the parent list item.
But (using first example from docs) it turns out that show
class must be applied to .dropdown-menu
element not on '.dropdown' or
.dropdown-toggle`.
Doc is not precise.
<div class="dropdown">
<button class="btn btn-secondary dropdown-toggle show" type="button" id="dropdownMenuButton" data-toggle="dropdown" aria-expanded="true">
Dropdown button
</button>
<ul class="dropdown-menu show" aria-labelledby="dropdownMenuButton" x-placement="bottom-start" style="position: absolute; will-change: transform; top: 0px; left: 0px; transform: translate3d(0px, 38px, 0px);">
<li><a class="dropdown-item" href="#">Action</a></li>
<li><a class="dropdown-item" href="#">Another action</a></li>
<li><a class="dropdown-item" href="#">Something else here</a></li>
</ul>
</div>