typescript version of coco/r