update files_js.ml: init more DRY