Refactored index for JS-parser