01 - Preheat the oven to 375°F. Lightly grease a 2-quart baking dish.
02 - Bring a large pot of salted water to a boil. Add green beans and cook for 4-5 minutes until bright green and just tender. Drain and immediately transfer to an ice bath to stop cooking. Drain again and set aside.
03 - In a large skillet over medium heat, melt butter. Add chopped onions and sauté for 2-3 minutes until translucent. Add garlic and mushrooms; cook for 5-6 minutes until mushrooms are softened and browned.
04 - Stir in flour and cook for 1 minute to form a roux. Gradually whisk in milk and broth until smooth. Bring to a simmer and cook for 3-4 minutes, stirring frequently, until thickened. Season with salt, pepper, and nutmeg.
05 - Remove from heat. Fold in green beans until evenly coated. Transfer the mixture to the prepared baking dish. Sprinkle half of the crispy fried onions over the top.
06 - Bake for 20 minutes. Remove from oven, sprinkle with remaining fried onions, and bake an additional 5 minutes until the topping is golden brown and crisp. Let cool slightly before serving.