Scrollable({Key key, double initialScrollOffset, Axis scrollDirection: Axis.vertical, ViewportAnchor scrollAnchor: ViewportAnchor.start, ScrollListener onScrollStart, ScrollListener onScroll, ScrollListener onScrollEnd, SnapOffsetCallback snapOffsetCallback, ScrollBuilder builder })

Initializes fields for subclasses.

The scrollDirection and scrollAnchor arguments must not be null.

Source

Scrollable({
  Key key,
  this.initialScrollOffset,
  this.scrollDirection: Axis.vertical,
  this.scrollAnchor: ViewportAnchor.start,
  this.onScrollStart,
  this.onScroll,
  this.onScrollEnd,
  this.snapOffsetCallback,
  this.builder
}) : super(key: key) {
  assert(scrollDirection == Axis.vertical || scrollDirection == Axis.horizontal);
  assert(scrollAnchor == ViewportAnchor.start || scrollAnchor == ViewportAnchor.end);
}