Preheat oven to 375˚F. Line two baking sheets with parchment paper or silicone baking mats. Set aside.
Cream together butter and sugar in a stand mixer, or using a handheld mixer, on medium speed until light and creamy. Beat in egg until just combined, and then beat in vanilla. Be sure to scrape down the sides as needed.
Add baking soda, flour, cinnamon, nutmeg, allspice, ginger, and salt to a medium bowl. Whisk together until combined.
With the mixer on low speed, slowly beat in dry ingredients until just incorporated. Stir in grated carrot by hand.
Using a dough scoop or large spoon, scoop dough out in 1 to 2 Tablespoonfuls onto prepared pans. Make sure to space them about 1 inch apart.
Bake 10 to 12 minutes, until cookies are golden around the edges. The cookies will still be very soft. Cool on the baking sheets for 5 minutes. Remove to a cooling rack to cool completely.
While cookies are cooling, make the frosting. Add butter and cream cheese to your cleaned out bowl of your stand mixer (or use a handheld mixer and bowl). Beat together until smooth. Add in vanilla and powdered sugar, beating until smooth. If the frosting is dry, beat in milk 1 teaspoon at a time until smooth.
Frost the cooled cookies as desired. Serve.
notes
Store cookies in an airtight container in the refrigerator for up to 5 days.