In other words, how to change Drawer
default background color using ThemeData
while setting light / dark themes for MaterialApp
widget.
I have searched for something like drawerTheme
but ThemeData
constructor does not have such property. Changing backgroundColor
etc doesn't work either. This topic suggests wrapping Drawer
with Theme
and use canvasColor
which thankfully works, but I'm searching for clean solution to achieve this using ThemeData
without need for wrapping every single Drawer
in my application.