Cook the pasta according to package directions until al dente. Save 1/2 cup of the cooking water before draining.
Heat olive oil in a large skillet over medium heat. Add onion and cook until soft and translucent.
Stir in garlic and mushrooms. Cook until the mushrooms release their juices and start to brown.
Add spinach and stir until wilted.
Pour in the cream, then stir in Parmesan until the sauce thickens slightly. Season with salt and pepper.
Add the drained pasta to the skillet. Toss well, adding pasta water if the sauce feels too thick.
Serve hot, topped with parsley if using.