You can position the tooltip on the left, right, top, bottom in the markup with a class name. This way if the tooltip is in the header you can use e.g. `tooltip-bottom`.
Having 10kb tooltip library for doing this automatically is a bit of an overkill for me [1].