bloc Questions

2

Solved

I'm using flutter_bloc library. My screen widget code looks looks this: class RegisterScreen extends StatefulWidget { RegisterScreen(); @override _RegisterScreenState createState() => _Regis...
Laterite asked 21/8, 2020 at 15:6

4

i have a screen with three widget [widgetA, widgetB, widgetC] and i have a bloc[BlocA] which is responsible for the data fetching and displaying on this screen i have three event [eventA, eventB, e...
Edgaredgard asked 11/2, 2022 at 8:6

5

I am attempting to use a bloc to manage the content of a dialog. I am fairly new to flutter. The page is defined as: @override Widget build(BuildContext context) { return Scaffold( appBar: AppBar...
Rhomb asked 12/11, 2020 at 18:17

2

Solved

I have a dialog and I wrap it in a blocbuilder to update it according to the type of state but the dialog just is built First time and after state has changed it doesn't rebuild. showDialog( conte...
Gervais asked 26/12, 2021 at 6:15

12

After closing the app, when I try to open it again, I'm getting the following error but it's only on iOS platform, Android works well. I have looked around and there are several SO questions and...
Jesuitism asked 27/8, 2019 at 11:14

5

Solved

I am using flutter bloc to make download progress percentage displayed but I keep getting this problem. I figured the problem arises in the onDone method but I couldn't figure out how to fix it. ER...
Smite asked 13/10, 2021 at 22:13

5

I've created a login screen where when user press on the login button it calls out an event LoginButtonOnPressedEvent. Below is my onLoginButtonOnPressedEvent function in my LoginBloc class. Futur...
Tomcat asked 9/4, 2022 at 6:5

11

Solved

I am trying to use the bloc pattern to manage data from an API and show them in my widget. I am able to fetch data from API and process it and show it, but I am using a bottom navigation bar and wh...
Scalade asked 5/4, 2019 at 13:25

7

Solved

So like most, i'm new to Bloc and flutter and dart and wrapping my head around. I've googled, looked through the posts here but haven't found really any answers. So this is about navigation with b...
Phillie asked 9/1, 2019 at 16:10

5

So, I have made a function in Cubit Class it is to get data from API. For now I just can get the data if I pressed a button. I wanna make the function automatically called when the page/screen is o...
Scofield asked 3/11, 2021 at 1:43

5

I am developing a mobile application using Flutter. I am using the flutter bloc package, https://pub.dev/packages/flutter_bloc for managing and setting up the bloc. But when the state change it is ...
Hartsfield asked 21/4, 2020 at 4:20

5

why am i getting the error? I couldn't find the reason. I'll be happy if you can help me. error screen You can check my issue on github
Dubious asked 11/4, 2022 at 12:25

0

I've just started learning flutter weeks back. I'm building a project with Go router and Bloc & get_it for dependency injection & also making use of flutter_native_splash for my splash scre...

5

I created a new flutter project where I put the flutter_bloc dependency but when I do flutter pub get I have this error. [bloc] flutter pub get Running "flutter pub get" in bloc... Becaus...
Maritamaritain asked 6/8, 2020 at 19:48

6

Solved

I am trying to create a listview with API data using bloc pattern following is the error: 'package:flutter/src/widgets/framework.dart': Failed assertion: line 5120 pos 12: 'child == _child': is ...
Ruthful asked 3/10, 2019 at 6:36

4

Solved

I am getting this issue while trying to run my code on DartPad. 'runZoned' is deprecated and shouldn't be used. This will be removed in v9.0.0. Use Bloc.Bloc.transformer instead... What is the cor...
Bute asked 12/9, 2022 at 7:37

2

Solved

I have an app that I build using Cubit I have two pages A and B.every thing works fine on its own. I use a change status cubit on both pages but when I move to the second page and pop to return to ...
Bookmark asked 10/10, 2022 at 14:43

1

I'm looking at the comment docs /// An optional [buildWhen] can be implemented for more granular control over /// how often [BlocBuilder] rebuilds. /// [buildWhen] should only be used for performan...
Bricebriceno asked 31/7, 2022 at 15:43

3

So I switched to Go router recently in my app since it is very easy to implement. But I am having trouble moving from Splash Screen to Login Screen. I have logic in my Splash Screen where I check i...
Ostrich asked 17/10, 2022 at 12:23

2

Solved

I wanted to nest the text Update BlocBuilder inside another BlocBuilder that controls its font size through a slider widget. But, I can't get it to work. Please help! BlocBuilder<SettingsBloc, ...
Edomite asked 29/3, 2020 at 4:40

4

Solved

While using BLoC library we store all the variables in a state class. But where to store TextEditingController, which does not change, but the value of it does? Let's say I have a state class like ...
Inlet asked 11/1, 2021 at 19:34

6

Solved

I'm creating a Flutter application. I'm added a BloC to my project for management state. I created a list with data. And I want to add item to ListView manually with button 'Add'. I'm wrote a code:...
Tomtit asked 19/12, 2021 at 13:12

5

Solved

I have a text field and a drop-down menu, both controlled by a Bloc. The problem I have is that as soon as the text field gets selected, it won't give up the focus if the user then tries to select ...
Kalahari asked 22/10, 2019 at 23:35

6

In the login view, if the user taps on the login button without having inserted his credentials, the LoginFailState is yield and the view reacts to it. If he taps again, this LoginFailstate is yiel...
Shirring asked 2/7, 2019 at 10:43

3

Solved

My goal is to create an app where the user can choose his preferred theme. I'm saving the user's choice with shared preferences so I can load it the next app start. The user can either select: - Da...
Jacklighter asked 23/2, 2020 at 17:9

© 2022 - 2024 — McMap. All rights reserved.