01 - Place the butter in a medium saucepan over medium heat. Cook, stirring, until butter foams and begins to brown and smell nutty, about 4–6 minutes. Immediately pour into a large mixing bowl and let cool 10 minutes.
02 - Add brown sugar and granulated sugar to the brown butter; whisk to combine. Stir in eggs and vanilla until smooth.
03 - In a separate bowl, whisk flour, baking soda, baking powder, salt, cinnamon, nutmeg, and ginger.
04 - Add the dry ingredients to the wet mixture and stir until just combined.
05 - Fold in oats, grated carrots, walnuts or pecans, and raisins if using.
06 - Cover and refrigerate dough 30 minutes for chewier cookies.
07 - Preheat oven to 350°F. Line two baking sheets with parchment paper.
08 - Scoop dough into 2-tablespoon balls, placing them 2 inches apart.
09 - Bake 11–13 minutes, until edges are set and centers look slightly underbaked. Let cool on baking sheet 5 minutes, then transfer to wire rack.
10 - Beat softened cream cheese and butter with powdered sugar and vanilla until smooth. Drizzle cooled cookies with glaze.