01 - Preheat oven to 400°F. Line a baking sheet with parchment paper.
02 - Heat olive oil in a skillet over medium heat. Sauté onion until softened, about 3 minutes. Add garlic and cook for 1 minute. Stir in chopped spinach and cook until wilted, 2 to 3 minutes. Remove from heat and let cool slightly.
03 - Combine ricotta, cheddar, parsley, oregano, nutmeg, salt, pepper, and cooled spinach mixture in a large bowl. Mix until thoroughly blended.
04 - On a lightly floured surface, roll out puff pastry sheets and cut each into 4 equal squares, yielding 8 squares total.
05 - Spoon 2 tablespoons of filling onto the center of each square. Fold over diagonally to create triangles and press edges firmly with a fork to seal.
06 - Place pastries on the prepared baking sheet and brush the tops with beaten egg to achieve a golden finish.
07 - Bake in the preheated oven for 18 to 22 minutes until golden and puffed.
08 - Allow pastries to cool slightly before serving.