added handling for compiled javascript applications and appropriate compiled vs non compiled loading approaches