sized method

Widget sized({
  1. double? height,
  2. double? width,
})

Implementation

Widget sized({double? height, double? width}) {
  if (width != null && height != null) {
    return SizedBox(
      height: height,
      width: width,
      child: this,
    );
  } else {
    return this;
  }
}