optimize loadJs method, add onload event;