Add listener in JS with dart callback function to update position