formated main js;