Lab #5 review
igor-leshkevych opened this issue · comments
@redd4ford good job, I like how you structured your app. The only thing I would change is to merge Theme
bloc and Weather
bloc: your Theme
depends entirely on weather (weather changes -> theme changes) which is clearly visible in code:
child: BlocConsumer<WeatherBloc, WeatherState>(
listener: (context, weatherState) {
//------> when weather changes
if (weatherState is WeatherStateSuccess) {
//------> theme changes
BlocProvider.of<ThemeBloc>(context).add(ThemeEventWeatherChanged(
weatherCondition: weatherState.weather.weatherCondition));
_completer?.complete();
_completer = Completer();
}
Your score is 20/20 👍