GitHub

    Table of contents

  1. Example
  2. Related Links

DatePicker

Edit this page

Shows a dialog containing a material design date picker.

Example

Future<DateTime> selectedDate = showDatePicker(
  context: context,
  initialDate: DateTime.now(),
  firstDate: DateTime(2018),
  lastDate: DateTime(2030),
  builder: (BuildContext context, Widget child) {
    return Theme(
      data: ThemeData.dark(),
      child: child,
    );
  },
);

Related Links