01 - Preheat the oven to 350°F. Grease and flour a 9-inch round or square cake pan, ensuring thorough coverage to prevent sticking.
02 - In a medium bowl, whisk together the flour, baking powder, baking soda, and salt until evenly blended. Set aside.
03 - In a large bowl, beat the softened butter and granulated sugar with an electric mixer on medium speed until light and fluffy, approximately 3 minutes.
04 - Add the eggs one at a time, mixing thoroughly after each addition. Stir in the vanilla extract until fully incorporated.
05 - Gradually add the dry ingredients to the butter mixture, alternating with buttermilk in three portions. Begin and end with dry ingredients. Mix until just combined; avoid overmixing to prevent tough texture.
06 - Toss the chocolate chips with 2 tablespoons flour in a small bowl until lightly coated. Gently fold the coated chips into the batter.
07 - Pour the batter into the prepared pan. Use a spatula to smooth the top surface evenly. Sprinkle with coarse sugar if desired.
08 - Bake for 35 to 40 minutes. Test for doneness by inserting a toothpick in the center; it should emerge clean or with a few moist crumbs.
09 - Allow the cake to rest in the pan for 10 minutes before carefully transferring to a wire rack. Cool completely before slicing and serving.