NestedScrollView constructor Null safety
- {Key? key,
- ScrollController? controller,
- Axis scrollDirection = Axis.vertical,
- bool reverse = false,
- ScrollPhysics? physics,
- required NestedScrollViewHeaderSliversBuilder headerSliverBuilder,
- required Widget body,
- DragStartBehavior dragStartBehavior = DragStartBehavior.start,
- bool floatHeaderSlivers = false,
- Clip clipBehavior = Clip.hardEdge,
- String? restorationId,
- ScrollBehavior? scrollBehavior}
Creates a nested scroll view.
The reverse, headerSliverBuilder, and body arguments must not be null.
Implementation
const NestedScrollView({
super.key,
this.controller,
this.scrollDirection = Axis.vertical,
this.reverse = false,
this.physics,
required this.headerSliverBuilder,
required this.body,
this.dragStartBehavior = DragStartBehavior.start,
this.floatHeaderSlivers = false,
this.clipBehavior = Clip.hardEdge,
this.restorationId,
this.scrollBehavior,
}) : assert(scrollDirection != null),
assert(reverse != null),
assert(headerSliverBuilder != null),
assert(body != null),
assert(floatHeaderSlivers != null),
assert(clipBehavior != null);