Is there any alternative way to change the Scaffol

2020-03-17 04:23发布

问题:

Currently Flutter Material directly not supporting editing Scaffold drawer controller. There is issue opened in their library to set width of drawer. Is there any we can access and change width? or Is there custom scaffold implementation exist to change the behaviour?

回答1:

Just copy the Drawer source to a MyDrawer class and change _kWidth there.

As @RémiRousselet suggested wrapping the Drawer with

SizedBox(width: myWith: child myDrawer)

is a much better way.