A Flutter widget that calls a callback when its child is resized.
-
Import the package
import 'package:flutter_resize_observer/flutter_resize_observer.dart';
-
Observe resizes
return ResizeObserver( onResized: (Size oldSize, Size newSize) { /* ... */ }, child: /* ... */, );
- amirh/size_observer
SizeChangedLayoutNotifier
(package:flutter/widgets.dart
)