Preheat the oven to 375°F (190°C). Prepare a 9x9-inch baking dish by greasing it lightly with butter or nonstick spray.
Cook the sweet potatoes: scrub them clean, then either roast whole wrapped in foil for 45–60 minutes until tender, or peel and chop into chunks and boil in salted water for 15–20 minutes until soft. Drain well.
Mash the sweet potatoes in a large bowl. Add brown sugar, butter, milk, vanilla, cinnamon, nutmeg, and salt. Taste and adjust seasoning or sweetness. The mixture should be creamy but firm enough to hold its shape.
Transfer the mashed sweet potatoes to the prepared baking dish and spread into an even layer.
If making a streusel topping: combine flour, brown sugar, chopped pecans (if using), and 3 tablespoons of melted butter in a small bowl. Mix until a coarse crumble forms, then sprinkle evenly over the sweet potatoes.
Top the casserole with an even layer of mini marshmallows, covering the surface. If using a streusel, apply the marshmallows either directly on the sweet potatoes or partially mixed with the streusel for pockets of crunch and marshmallow.
Bake in the preheated oven for 15–20 minutes, or until marshmallows are puffed and just beginning to brown. For a deeply toasted top, switch the oven to broil for 1–2 minutes—watch very closely to avoid burning.
Remove from the oven and let the casserole rest for 5–10 minutes. The marshmallows will set slightly while still being gooey. Serve warm as a side dish.