Having problem inside the layout file
Bengate-Technologies opened this issue · 0 comments
Bengate-Technologies commented
lib/layout.dart:17:29: Error: Required named parameter 'mediumScreen' must be provided.
body: ResponsiveWidget(largeScreen:LargeScreen(), smallScreen:SmallScreen(),),
^
lib/helpers/responsiveness.dart:14:9: Context: Found this candidate, but the arguments don't match.
const ResponsiveWidget(
^^^^^^^^^^^^^^^^
lib/helpers/responsiveness.dart:43:16: Warning: Operand of null-aware operation '??' has type
'Widget' which excludes null.
- 'Widget' is from 'package:flutter/src/widgets/framework.dart'
('/C:/src/flutter/packages/flutter/lib/src/widgets/framework.dart').
return mediumScreen ?? largeScreen;
^
lib/helpers/responsiveness.dart:46:16: Warning: Operand of null-aware operation '??' has type
'Widget' which excludes null. - 'Widget' is from 'package:flutter/src/widgets/framework.dart'
('/C:/src/flutter/packages/flutter/lib/src/widgets/framework.dart').
return smallScreen ?? largeScreen;