In a medium bowl, whisk together the all-purpose flour, baking powder, baking soda, and salt. This will be our dry mixture.
In a large mixing bowl, cream together the softened butter, brown sugar, and granulated sugar using an electric mixer on medium speed. Beat until the mixture is light and fluffy, about 2-3 minutes.
Add the eggs, one at a time, mixing well after each addition. Then, stir in the vanilla extract until fully incorporated.
Gradually add the dry mixture to the wet mixture, mixing on low speed until just combined. Be careful not to overmix; we want a tender dough.
Once the dough is formed, divide it into two equal portions. Shape each portion into a disk, wrap them in plastic wrap, and refrigerate for at least 1 hour.
While the dough is chilling, prepare the brown sugar filling. In a small bowl, combine the brown sugar, cornstarch, and cinnamon. Mix well until all the ingredients are evenly distributed.
Set the filling aside.
After the dough has chilled, preheat your oven to 350°F (175°C) and line two baking sheets with parchment paper.
Take one disk of dough out of the refrigerator. On a lightly floured surface, roll out the dough to about ¼ inch thick.
Using a sharp knife or a pizza cutter, cut the rolled-out dough into rectangles, approximately 3×4 inches. Aim for about 12 rectangles from each disk, giving you a total of 24 rectangles.
Repeat the rolling and cutting process with the second disk of dough.
Take one rectangle of dough and place about 1 tablespoon of the brown sugar filling in the center.
Take another rectangle of dough and place it on top of the filled rectangle. Press the edges together to seal. Use a fork to crimp the edges for a decorative touch.
Repeat this process until all the rectangles are filled and assembled. Place the assembled cookies on the prepared baking sheets, leaving some space between each cookie.
Brush the tops of the cookies with a little milk.
Place the cookies in the preheated oven. Bake for 12-15 minutes, or until the edges are lightly golden and the tops are set.
After baking, remove the cookies from the oven and let them cool on the baking sheets for about 5 minutes. Then, transfer them to a wire rack to cool completely.
In a small bowl, whisk together the powdered sugar and 2 tablespoons of milk until smooth. Adjust the consistency with more milk if necessary.
Drizzle the icing over the cooled cookies and add sprinkles if desired.
