-
Heat the oven to 350°F. Grease a rimmed 13×18-inch half-sheet pan and line it with parchment paper.
-
In a medium bowl, whisk together the flour, baking powder, baking soda, cinnamon, ginger, and salt.
-
In a large bowl, whisk together the dark brown sugar, granulated sugar, and oil. Add the eggs one at a time, whisking after each addition. Stir in the vanilla.
-
Add the dry ingredients to the wet ingredients. Mix just until combined.
-
Fold in the grated carrots and well-drained pineapple. Spread the batter evenly in the prepared pan.
-
Bake for 18–24 minutes, checking for doneness around 15 minutes. The cake is done when the center springs back lightly and a toothpick inserted in the center comes out with a few moist crumbs.
-
Let the cake cool completely. For easier cutting and stacking, chill the cooled cake briefly. Cut it into four equal rectangles, approximately 9×6½ inches each.
-
To make the frosting, beat the cream cheese and butter until smooth and fluffy. Beat in 3¼ cups powdered sugar, the vanilla, and ½ packet of chai mix. Taste and add more chai mix gradually, up to one packet total. Add more powdered sugar as needed for a thicker frosting.
-
Place one cake rectangle on a serving plate. Spread frosting over it, then add the next cake layer. Repeat until all four layers are stacked. Frost the top and sprinkle with chopped walnuts.
-
Refrigerate the assembled cake for about 30 minutes before slicing.