A JavaScript utility which automatically aligns position of an overlay element.
<script src="dist/alignme.min.js"></script>
var alignMe = new AlignMe($overlay, {
relateTo: '.draggable',
constrainBy: '.parent',
skipViewport: false
});
alignMe.align();
relateTo
Selector of element which you are going to align with. This one is required.constrainBy
Selector of constrait element. Default isnull
.skipViewport
Whether to ignore the viewport or not. Default isfalse
.