jsbrowser: API to get resources from current page