01 - Preheat oven to 350°F. Line two baking sheets with parchment paper.
02 - Whisk together flour, baking powder, baking soda, salt, cinnamon, nutmeg, and ginger in a medium bowl.
03 - Beat butter, granulated sugar, and brown sugar in a large bowl until creamy and fluffy, about 2-3 minutes.
04 - Add egg and vanilla extract to the butter mixture, mixing until well combined.
05 - Gradually mix dry ingredients into the wet ingredients until just combined.
06 - Fold in grated carrots, oats, walnuts or pecans if using, and raisins if using.
07 - Drop dough onto prepared baking sheets using a tablespoon or small cookie scoop, spacing about 2 inches apart.
08 - Bake for 11-13 minutes until edges are golden and centers are set. Cool on baking sheet for 5 minutes, then transfer to wire rack to cool completely.
09 - Beat cream cheese, powdered sugar, milk, and vanilla together until smooth. Drizzle over cooled cookies using a spoon or piping bag. Allow glaze to set before serving.