Skip to main content
Filter by
Sorted by
Tagged with
Tooling
1 vote
5 replies
72 views

Until now, I've only used RiverPod and Provider to do status management. I think they only use the same technology, so I want to proceed with the project using new status management, but I'm agonizing ...
정지윤's user avatar
Advice
0 votes
2 replies
92 views

I used RiverPod only every time to manage my condition, but I want to use BLOC this time, so I'm going to study it. But I'm not sure how to move the view, so I'm posting a question! I was wondering if ...
정지윤's user avatar
Best practices
1 vote
2 replies
52 views

This is the first time I'm using bloc so it's a bit confusing for me. I have a workout model, and a repository with methods to fetch all workouts, add new, update, or delete a workout. Initially I ...
Anas Ansari's user avatar
0 votes
2 answers
206 views

I want to share a single instance of a Cubit between both RouteA and RouteB. Passing the Cubit via $extra results in a error: state.extra is an invalid type. Using BlocProvider.value inside RouteB ...
Hercule Poirot's user avatar
0 votes
1 answer
52 views

I am trying to navigate to QuestCartScreen after tapping on discover more quests button.I am using bloc for state management. But it is taking long time to navigate. The action occurs from homepage ...
Vinaya Augusthy's user avatar
0 votes
1 answer
60 views

State calling multiple times. When I am clicking anyone google or facebook for login then my state gets called two times. I am not understanding what is issue. I have 2 pages 1. intro.dart and 2. ...
Deepak's user avatar
  • 2,364
2 votes
0 answers
58 views

I'm using Flutter with BLoC to update user data. The problem is that after calling the update event, the UI doesn't reflect the updated data immediately. Instead, it shows the previous value on the ...
yusuf's user avatar
  • 43
0 votes
1 answer
93 views

I'm working with Flutter Bloc for state management. I have a ThemeBloc that toggles between light and dark modes, and I want to trigger AppBloc to perform an action whenever the theme changes. However,...
yusuf's user avatar
  • 43
0 votes
2 answers
86 views

I have a ListView in my first screen that displays a list of addresses. When the user navigates to the second screen to add or edit an address and then comes back to the first screen, I want the ...
surya nadiminti's user avatar
1 vote
1 answer
54 views

I have a bloc event, and I'm writing test for it, my event have one case that will add another event, that I don't want to include in test because I'm focusing on one event, so I have tried multiple ...
makri aymen abderraouf's user avatar
0 votes
1 answer
33 views

I'm working on a Flutter app where users need to grant photo access permission to load gallery images. I'm using Permission.photos for Android 33+ and Permission.storage for older versions. The ...
Yash Trivedi's user avatar
0 votes
2 answers
61 views

Please help me choose the right way. I have an application with a list of photos, and you can like each photo. You can like it from the general list and on the screenshot of one photo. The problem is ...
Aidar's user avatar
  • 91
0 votes
2 answers
73 views

I have a widget/screen that shows some content. At the bottom of the page is a "Refresh" button. What is the best way to show a "Refreshing" overlay on tap of the button without ...
gvaish's user avatar
  • 9,414
0 votes
1 answer
91 views

in main.dart void main() { runApp(MyApp()); } class MyApp extends StatelessWidget { @override Widget build(BuildContext context) { return MaterialApp( debugShowCheckedModeBanner: ...
Dat Minh's user avatar
-1 votes
1 answer
82 views

i follow the migration guide https://bloclibrary.dev/migration/ but i get this error DartError: LateInitializationError: Field '__storage' has not been initialized. dart-sdk/lib/_internal/...
Alin1233's user avatar
0 votes
0 answers
45 views

I want to create a custom wrapper as AsyncValue<T> that can hold an asynchronous state (loading, data, error) and be used in a Cubit state class. The goal is to avoid creating multiple Cubits ...
Roy Krueger's user avatar
1 vote
1 answer
64 views

I need to execute multiple events from different Blocs synchronously, ensuring that each event completes before the next one starts. Here's the current code: context.read<PaymentBloc>().add(...
justinprabhakaran's user avatar
0 votes
1 answer
85 views

I am trying to test how is my widget reacting to BloC state changes. This is how my test look like: class MockAuthBloc extends Mock implements AuthBloc {} void main() { initHydratedStorage(); ...
Karol Wiśniewski's user avatar
1 vote
2 answers
94 views

I have a textfield that is inside a BlocBuilder, so that the background color of the textfield changes depending on a parameter of the bloc (if the text entered in the textfield is empty or not). ...
fanfan's user avatar
  • 37
0 votes
2 answers
64 views

I've been using cubit for my flutter project. This is how my main.dart looks like, void main() async { WidgetsFlutterBinding.ensureInitialized(); // Set system preferences before running the app ...
Arun Xena's user avatar
0 votes
1 answer
117 views

I'm facing an issue with accessing my CubitSubject provider in a specific screen. I have a MultiBlocProvider in the root of my app, and I'm trying to access the CubitSubject in the SubjectsView screen....
TAHA HORANE's user avatar
0 votes
0 answers
151 views

Hi i have this problem where my app failed to navigate correctly to a new page after getting success state, here what it should be: First Page -> Second Page (listen when success) -> Last Page ...
Parama Artha's user avatar
1 vote
0 answers
59 views

So I decided on a BLoC pattern for my flutter app and so far it worked. But then I also introduced the hydrated bloc plugin for persistence. All I can find as examples in hydrated bloc is the same ...
user23508983's user avatar
0 votes
0 answers
236 views

I'm trying to learn BLoC pattern using flutter_bloc package in flutter. I'm aslo using socket_io_client package to connect to a local Node.js server. I have 3 problems: The first, when the state ...
user10033434's user avatar
1 vote
1 answer
226 views

I encountered an issue when I wrapped my MaterialApp widget in a BlocBuilder. I expected the entire widget tree to rebuild whenever a new state was emitted. However, I noticed that some widgets didn’t ...
DOT NET OLD DEV's user avatar
0 votes
3 answers
175 views

I'm using Flutter bloc cubit and equatable to manage a simple form. in the birthday field, i check if it's a valid date and then send it to bloc and works fine. but if user then changes the date i ...
Erick Galván's user avatar
-1 votes
1 answer
73 views

i am building an app with flutter and firebase backed in which the user can go to a profile screen to edit it. The profile has 2 parts, a view one, where the user can view all its data, verify its ...
alberto sansegundo's user avatar
0 votes
2 answers
97 views

I'm encountering the following error in my Flutter application: Error: Could not find the correct Provider<SettingsBloc> above this BlocListener<SettingsBloc, SettingsState> Widget. I'm ...
Milton Mariños's user avatar
0 votes
2 answers
70 views

import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:moms/features/chat/domain/entities/message_entity.dart'; import 'package:moms/features/chat/domain/usecases/send_message.dart'; import '...
Nishant's user avatar
  • 94
-1 votes
1 answer
169 views

I'm developing a Flutter application using the BLoC pattern. I have a single UI page that interacts with a BLoC that handles 5 events and 10 states. My requirement is as follows: When I fire an event ...
Jay Parmar's user avatar
0 votes
1 answer
75 views

Error: Could not find the correct Provider above this RegisterScreen Widget This happens because you used a BuildContext that does not include the provider of your choice. There are a few common ...
Taki's user avatar
  • 3,828
1 vote
0 answers
57 views

I have a state (formState) and multiple form-based input widgets like TextFormField, Dropdown, and others. Each widget has an onChange function and events, and the widgets are wrapped around a ...
Pe be's user avatar
  • 43
0 votes
1 answer
47 views

I have a page which contains a button. When the user presses the button, a dialog box shows up which contains a bunch of textfields, etc. There is a toggle in that dialog box which changes the ...
Tloz's user avatar
  • 359
1 vote
1 answer
79 views

I am learning flutter and flutter_bloc:8.1.6. I am developing a simple app where a user can add or edit their transactions and see a list of transactions when a new transaction is added or updated. ...
drunkZombie's user avatar
1 vote
1 answer
46 views

when I use the following code snippet in flutter import 'package:flutter/material.dart'; import 'package:flutter_app/features/note/presentation/screens/note_list.dart'; import 'package:flutter_app/...
Emam Kownine's user avatar
1 vote
1 answer
106 views

I needed to keep variables across few pages. I created Cubit class for this, but in my thinking I didn't needed any state for this as my widgets doesn't depends on anything. I just need to keep data ...
Karol Wiśniewski's user avatar
0 votes
1 answer
63 views

I'm using bloc with flutter to handle business logic and so on , code is working fine except when i navigation from HomeScreen to another screen , upon coming back to HomeScreen , all data from api is ...
Taki's user avatar
  • 3,828
1 vote
1 answer
706 views

I’m working on a Flutter application using the flutter_bloc package for state management. I have a page that requires fetching data from multiple API endpoints. Scenario: The page displays data from ...
suhail mk's user avatar
0 votes
2 answers
83 views

void main() { runApp(const MyApp()); } class MyApp extends StatelessWidget { const MyApp({super.key}); @override Widget build(BuildContext context) { return MaterialApp( title: '...
Goziem Onuoha 's user avatar
0 votes
1 answer
103 views

I am getting this error GetIt: The compiler could not infer the type. You have to provide a type and optionally a name. Did you accidentally do var sl=GetIt.instance(); instead of var sl=GetIt....
mudit bansal's user avatar
0 votes
1 answer
112 views

https://gist.github.com/ArpanMondalGITHUB/7012a4af48bed19d64eefc325fc23901 I am trying to sign up using Bloc and Firebase, but whenever I connect the BlocConsumer to the sign-up page form it gives me ...
ARPAN MONDAL's user avatar
0 votes
1 answer
45 views

how are you, I am a novice developer and I am currently creating an app, in which I use Bloc Patter, I am obtaining data that is displayed on a main screen from Cloud Firestore and so far everything ...
Gorge Reyes's user avatar
0 votes
1 answer
560 views

MultiBlocProvider( //option 1 [ BlocProvider( create: (BuildContext context) => BlocA(), ), // option 2 BlocProvider( create: (BuildContext context) => getIt<BlocA>(), ) ], child: ...
stackcen's user avatar
  • 173
0 votes
2 answers
129 views

I am trying to get data from local storage and display it on the screen using flutter_bloc, but I am getting the error "type 'String' is not a subtype of type 'Map<String, dynamic>'". ...
Meet Bhanderi's user avatar
1 vote
1 answer
215 views

I'm using Flutter with flutter_bloc, and I'm in front of the following scenario. Scenario I have a Cubit with two methods beings loadFoo and loadBar: class UserCubit extends Cubit<UserState> { ...
SyncroIT's user avatar
  • 1,578
0 votes
1 answer
32 views

I have a textfield with an onchnaged function which calls the validate service then returns the value to the widget. i used print values to debug the code just to make sure everything was working fine....
Great Daddy Dragon's user avatar
0 votes
1 answer
116 views

I'm currently developping an ERP application but I'm quite new to BLoC state management. I'm mostly a back-end developper, so maybe I'm doing things wrong. I have a customer model that have 40+ ...
Neibue's user avatar
  • 9
1 vote
2 answers
311 views

I initially created one Cubit to manage the state of my screen, but as it became too complex, I refactored it into four separate Cubits. Now, to make the screen function as intended, I had to ...
Hercule Poirot's user avatar
0 votes
1 answer
263 views

I have a bloc registered in locator (Get_it). I am using the bloc in multiple UI components. But once i trigger the ui update event from some another screen it gives Cannot add new events after ...
Abhijith Konnayil's user avatar
0 votes
2 answers
691 views

I have a piece of code where i need to call two bloc events sequentially the issue is that the first event is fired and api is called but the second is not being called , i tried to debug my code and ...
Taki's user avatar
  • 3,828

1
2 3 4 5
21