Heat the oven to 180ºC (160ºC fan) 375ºF, gas 5. Heat the oil in a small pan and gently cook the shallot and garlic until soft but not browned. Remove from the heat and set aside.
Cook the washed spinach in a large pan until just wilted then drain, squeeze out any excess moisture and roughly chop.
Cut 8 circles from the pastry, each about 10 cm/4 in in diameter and place on a greased baking sheet. Brush the edges of each circle with the beaten egg yolk.
Mix together the shallot mixture, spinach and grated cheese, season with salt and pepper and place the mixture on the top of each pastry circle. Bake in the oven for 10 - 12 minutes or until golden brown.