Preheat the oven to 375 degrees. Line a baking sheet with parchment paper.
Heat the olive oil in a medium sized pan over medium heat. Add the beaten eggs (with a dash of milk) mixture and cook. After a few minutes, add the onions, garlic, parsley and spinach. Mix together for another 2-3 minutes. Season with salt and pepper. Don’t worry about cooking everything all the way through. You are going to bake these in the oven to finish cooking.
Roll out the thawed puff pastry. Cut the puff pastry sheet so you have 4 equal square pieces. If using ham, lay down the ham, layer on the egg mixture and top with cheese.
Grab the top and bottom corners and bring them to the center, pinching them together to seal them. Repeat with the side corners so you end up with a little pastry package square.
Brush the puff pastry with the egg wash. Bake for 25- 30 minutes, or until the pastries are golden brown.
Garnish with green onions and freshly grated Parmigiano-Reggiano. Serve while hot.