Preheat the oven to 180C / 350F.
Place the dry ingredients in a food processor and pulse to combine.
Add 1 egg, butter, cream cheese and vanilla and pulse until a sticky batter. Don’t over-mix.
Shape the dough to form a ball. Wrap in clingfilm or tin foil and place in the freezer for 10 - 15 minutes until chilled. This stops it being sticky and makes it easy to roll.
Meanwhile make the filling. Place the raspberries in a non-stick pan. Heat on medium until soft, stirring a couple of times to prevent sticking, and squash the raspberries with the back of a spatula. About 5 minutes. Turn off the heat. Add the xanthan gum and stir to combine. Allow to fully cool.
Cut the dough in two. Take one piece and roll between two sheets of greaseproof paper. Fold over the edges and re-roll. This will give you more of a rectangle shape.
Cut the edges off and cut into 4 rectangles. Repeat with the remaining ball. Use any leftovers to form the last two rectangles. Depending on how thin you roll it you should get 10 rectangles.
Place the rectangles on a greaseproof lined baking tray. Brush half with beaten egg wash.
Split the filling into 5 and add to the centre of the non egg-washed rectangles. Spread slightly with the back of a spoon leaving about 1cm all the way around. Approx 1 tablespoon of filling per pop tart.
Add the egg washed rectangle to the base with the filling and place in the freezer again for 10 minutes. This stops the dough sticking and breaking when you seal with a fork.
Press to seal the edges with a fork and add 2 - 3 fork marks to the top. This will let out any steam and stop them exploding. Don’t go all the way through the pastry, just the top rectangle in depth.
Cook for 15 - 17 minutes or until golden. Option to brush with a little melted butter. Allow to cool.
Mix the icing in a bowl with a teaspoon until smooth. Add the water a few drops at a time until to your desired thickness, approximately 1 tbsp. Ice the pop tarts using the back of a spoon and allow to cool to set. Option to sprinkle with freeze dried raspberry powder or sugar free sprinkles.