Bring a large pot of water to a boil over high heat. Rinse all produce. Trim and discard woody bottoms of asparagus, then cut into .5-inch pieces. Peel shallots, halve, and thinly slice. Pick 3 mint leaves and discard stem. Stack leaves, thinly slice, and set aside for garnish. Save remaining mint for another recipe, or add to cold water for a refreshing drink!
Heat 2 tablespoons olive oil in a large pan over medium heat. When oil is shimmering, add whole garlic cloves and shallots and cook until shallots are soft and translucent, about 3 minutes. Add white wine and cook until reduced by half, about 3 minutes more.
Add asparagus to pan with aromatics and cook until softened and bright green, about 5 minutes. Add peas and season with 1 teaspoon salt and black pepper as desired. Stir in spinach to wilt, 1-2 minutes more, then remove from heat. Remove and discard whole garlic cloves. Transfer vegetables to a bowl and cover with foil to keep warm. Reserve pan for Step 5.
Season pot of boiling water generously with salt and add gnocchi. Cook until tender and floating to the surface, 2-3 minutes. Reserve 1.25 cups gnocchi cooking water, then drain (see Recipe Tip).
Wipe pan from vegetables clean and add butter over medium-high heat. When butter is foamy, add cooked gnocchi and stir to coat with butter. Add reserved gnocchi cooking water and allow to come to a boil. Then, add Parmesan and cracked black pepper, vigorously stirring until sauce thickens and becomes silky smooth, about 2 minutes (if your sauce is too thick, stir in 1-2 tablespoons warm water to loosen it). Remove pan from heat.
Add cooked vegetables to pan with gnocchi and stir to combine. Taste and add salt as needed. Transfer cacio e pepe gnocchi to serving dishes and garnish with mint. Dig in!