data attribute and
title on the HTML element you wish to have a tooltip.
The generated markup of a tooltip is rather simple, though it does require a position (by default, set to top by the plugin).
As mentioned above, you must initialize tooltips before they can be used. One way to initialize all tooltips on a page would be to select them
⛶ main.js // Tooltip Trigger ❯❯❯❯ [data-bs-toggle="tooltip"] attribute, like so:
And with custom HTML added:
data-bs-html="true"
Hover over the buttons below to see the four tooltips ↗ directions: top, right, bottom, and left. Directions are mirrored when using Bootstrap in RTL.
data-bs-placement=""
title or data-bs-title in your HTML. When title is used, Popper will replace it automatically with data-bs-title when the element is rendered.