Bind app init to document load