Milk production is also a continuum of data samples over the life of the animal. Eating the animal is one data sample and you can’t duplicate the animal after collecting the data.
Selecting for milk production would be a lot more accurate than selecting for meat tastiness, longevity or even, to an lesser extent, health.