Preheat oven to 375°F.
Grate apples against the large holes on a box grater (watch your fingers!). Don't worry if you don't use the entire apple, it gets too tricky when you get to the end.
In a medium saucepan, melt butter over low heat. Add grated apples and stir to combine.
Add brown sugar, cornstarch or flour, lemon juice, cinnamon, ginger and salt. Turn heat up to medium and stir constantly until the mixture is completely combined and has thickened (10 minutes or so). Remove from heat to cool.
Roll out your pastry sheet to be around 11x15". Cut each sheet into 8 equally-sized rectangles.
On a baking sheet prepped with a non-stick silicon mat or parchment paper, place 4 of the pastry rectangles with some space between each.
Spoon a heaping tablespoon (or 2, as long as you're evenly distributing the filling you prepared) of filling into the center of each rectangle. Leave yourself about ½" space around the edges.
Brush each of the remaining 4 pastry rectangles with your egg wash, and place each wash-side down on top of the filled rectangles.
Use a fork to seal the edges, all the way around, and then prick them all over the top with the fork.
Bake for about 25 minutes, or until golden brown. Let cool on pan for 5 minutes, then transfer to a wire rack to cool completely.
While they cool, prep your icing! In a small bowl, use a hand mixer to beat cream cheese, powdered sugar and vanilla extract until completely combined.
Spoon into a piping bag or plastic bag with a small corner cut off, and pipe onto each pastry. Serve immediately and enjoy the nostalgia!