Fix for loading in HEAD

The generation of the 'compat' object requires the document BODY to
exist and this is not available if Overscroll is loaded into the HEAD.
The setup of compat has been moved into the entry-point function.