Boil the pasta. Cook the pasta in a large pan of salted water until just shy of done — 1 minute less than the packet says. Save a mug of the starchy pasta water before draining.
Brown the mushrooms. Heat the olive oil in a large deep pan over high heat. Add the mushrooms in a single layer and don't move them for 3 minutes — they need to brown, not steam. Stir and cook 3 more minutes until golden.
Build the sauce. Lower the heat, add the onion and cook 3 minutes until soft, then the garlic and thyme for 1 minute. Pour in the cream and stock and simmer gently for 3 minutes until slightly thickened.
Wilt the spinach. Add the spinach a handful at a time, stirring until it wilts into the sauce. Season with salt, pepper and the chilli flakes if using.
Bring it together. Tip the drained pasta into the sauce with the Parmesan and a splash of pasta water. Toss over the heat for 1–2 minutes until the sauce clings to every piece and turns silky.
Serve. Divide between warm bowls, scatter with parsley and extra Parmesan, and eat immediately.