Fixed bug where event listener would be attached multiple times; typing is now publishing api via data.