Delayed scripts to document_end, removing need for onready