Goats, because they are browsers cannot be sustained on grass only. However, I do not believe that they can't survive without grain. Our meat goats (granted they're young and have not yet been pregnant), are doing just peachy fine on 2.5-3 acres of 'pasture' - maybe one acre of grass, an acrish of woods and an acre-ish of brush (mostly multiflora rose), with only 1 cup of grain a day which is basicly just a treat to convince them to come to the barn at night to be locked up safely
There are lots of meat goats that are raised on huge pastures out west and in other countries. I don't see why you couldn't do so with a dairy goat, although you might not get as much milk.
One of the things that I've read about dairy goats and pasture issues is that if you have them on huge pastures with lots of browse (what they need), and because they're bred to have big udders and they tend to get caught up in the brush, and get hurt that way. Also, because of their varied diets of browse/brush they're milk can often have an off flavor. Which is obviously unfavorable!!
But, I have no doubt that its possible to do. Especially if you're feeding high quality hay free choice, and have a nice big area to roam around with lots of brush and browse. Lots of dairy people will tell you that its 'impossible' to raise dairy cows on grass only, but we obviously know thats not true - theres lots and lots of folks doing it, and more and more every year. Indeed scaling up grass-fed cattle/dairy farming is something to strive for, in order to keep grain prices down, save tons of oil (both because of not needing tractors to tend to the grain and not needing the oil to make pesticides/herbicides/fertilzers for their growth), and sequester carbon (vs putting tons of it more into the atmosphere every year). To say that its 'impossible' or 'irresponsible' to only feed a lactating animal what they evolved to eat over thousands of years is a bit crazy, IMO. Its like saying people can't live without sugar, white bread, or other refined foods - of course we can! And so can animals!!