added preloader option, added javascript output option