Onions and garlic can be used at any stage in their development. Onion greens are quite popular too, though I have never tried garlic greens.
It is necessary to dry these bulbs after harvest if you want them to store well. Otherwise they will want to sprout and grow again.
Gardening at 5000 feet elevation, zone 4/5 Northern Utah, Frost free from May 25 to September 8 +/-