updates to javascript wrapper