Preheat oven to 350°F. Grease a 9x13 pan or two 8-inch round pans.
In a large bowl, whisk together sourdough discard, eggs, oil, maple syrup, applesauce, and vanilla until smooth.
Stir in the grated carrots.
In a separate bowl, mix the flour, baking soda, baking powder, salt, and spices.
Slowly add the dry ingredients to the wet mixture and stir until just combined. Fold in nuts, coconut, or raisins if using.
Pour batter into prepared pan(s). Smooth the top.
Bake for 30–35 minutes or until a toothpick comes out clean.
Cool in pan for 10 minutes, then transfer to a wire rack.