Set puff pastry on the counter to thaw.
Melt butter in a large frying pan over medium heat. Add the onions, stir frequently and cook until soft and golden.
Meanwhile, wash the spinach, dry thoroughly, then roughly chop.
Once onions are done, add the garlic to the pan and cook until fragrant, about 30 seconds.
Add spinach to pan, season with black pepper, and cook by turning constantly with tongs until the spinach is wilted.
Add spinach, cream cheese, herbs, onion flakes, and salt to a large bowl. Mix well with a fork.
Once puff pastry is soft enough to handle, unfold sheets and place on lightly floured surface.
Divide cream cheese mixture between two puff pastry sheets, lightly spreading over entire surface.
Beginning with one edge, roll each pastry sheet into a log. Place rolls on a parchment lined baking sheet and refrigerate for at least 30 minutes.
Preheat oven at 400º F.
Remove rolls from refrigerator and slice into ½ slices. Place slices back on parchment lined baking sheet and bake for about 25 minutes or until golden. Let cool for a few minutes, and serve warm. Pinwheels can be refrigerated for 2-3 days and can be served cold as well.
If using frozen spinach, allow to thaw and then squeeze to remove excess moisture. Recipe calls for about 1 cup of cooked spinach.