jquery.iamin (npm): jquery-plugin that will set your element on a side of its parent within body (if it can) or at start of the body (if can't).
Keywords: jquery-plugin|positioning