Preheat your oven to 350°F (175°C). Line your baking pan with parchment paper for easy removal and set it aside.
In a medium saucepan over low heat, melt the butter or coconut oil until completely liquid. Remove from heat and let it cool slightly.
In the same saucepan, add the coconut sugar to the melted butter or coconut oil. Whisk until well combined. Then, stir in the cocoa powder and vanilla extract. Add the lightly whipped eggs and mix until smooth.
Slowly fold in the white whole-wheat flour and salt into the wet mixture. Mix until just combined—be careful not to overmix.
Gently fold in the chocolate chips and, if using, the walnut pieces, ensuring they are evenly distributed throughout the batter.
Pour the brownie batter into the prepared baking pan, spreading it evenly. Bake in the preheated oven for 20-25 minutes, or until a toothpick inserted into the center comes out with a few moist crumbs.
Allow the brownies to cool in the pan for about 10 minutes, then lift them out using the parchment paper. Let them cool completely on a wire rack before slicing into squares.