Drawer constructor Null safety

const Drawer(
  1. {Key? key,
  2. Color? backgroundColor,
  3. double? elevation,
  4. ShapeBorder? shape,
  5. double? width,
  6. Widget? child,
  7. String? semanticLabel}
)

Creates a Material Design drawer.

Typically used in the Scaffold.drawer property.

The elevation must be non-negative.

Implementation

const Drawer({
  super.key,
  this.backgroundColor,
  this.elevation,
  this.shape,
  this.width,
  this.child,
  this.semanticLabel,
}) : assert(elevation == null || elevation >= 0.0);