Ensure js is loaded properly