Questions tagged [flutter-streambuilder]

192 questions
0
votes
0 answers

The following assertion was thrown building StreamBuilder>: setState() or markNeedsBuild() called during build

This Overlay widget cannot be marked as needing to build because the framework is already in the process of building widgets. A widget can be marked as needing to be built during the build phase only if one of its ancestors is currently building.…
0
votes
0 answers

Using .isGreaterThanOrEqual in .where method doesn't correctly sort Firebase Firestore documents in Flutter

I am trying to create simple Firebase Firestore query that allows the user to view the top forums from the previous day at most. This is the query I am currently using inside a ```StreamBuilder``` in Flutter. _stream = FirebaseFirestore …
0
votes
1 answer

Flutter Firestore streambuilder returning an error

I have a collection called Todos in Firestore with 3 possible properties (id, text and checked). So far i have succeeded on creating and saving todo's. Now i want them in a Listview but it returns an error on hot restart: ════════ Exception caught…
0
votes
1 answer

RangeError (index): Invalid value: Valid value range is empty: 0,,,can anyone tell me what is the problem in my streambuilder method?

Here is the error: Exception caught by widgets library ═══════════════════════════════════ The following RangeError was thrown building StreamBuilder\\>(dirty, state: \_StreamBuilderBaseState\,…
0
votes
2 answers

How to delete documents that contain a certain value in one of the fields. Firestore, Flutter

enter image description here I have these documents, which contain data about each task I add to the list in my app. child: StreamBuilder( stream: _tasks.snapshots(), builder: (context, AsyncSnapshot streamSnapshot) { if…
0
votes
1 answer

Make a stream wait for data to assign a late property

I have following code. I need to assign a late userName (not stored in database BID table) from the Bid Object that i retreive from the firestore with a stream. The userName can be found in another table in the database (USER table). I need to…
0
votes
1 answer

Flutter Row() - Align 3 widgets evenly in any amount of Columns

I need to show whole my options(Cyties) since Firebase DB in my app so I would like create somethig similar to the screenshot I posted and not quite sure how to. The only way I know to do it is with ListTile and is not the idea.app Colombia from…
0
votes
1 answer

Flutter Firebase Multiple Document Id StreamBuilder

I have a document id list in my code, I want to use this id list in my new query. How can I enter multiple document id's? StreamBuilder( stream: Firestore.instance.collection("Dersler") .document(dersler).collection("Kategori") …
0
votes
0 answers

Combine two streams to then assign to a custom user model

I'm making an app with authentication using Flutter and Firebase. I'm using StreamBuilder to pass the data of the user who is logged in to a custom user model that I created. Here's how the custom user model looks: User? userSnapshot; class User { …
0
votes
1 answer

Pagination function that adds data to StreamController - Flutter

I am trying to implement pagination in my app but it's not working very well. So far, the code works to get the first 10 posts and their users but after that, it goes downhill. When a user reaches the last post, the getData() function is called…
Globe
  • 169
  • 11
0
votes
0 answers

type 'CombineLatestStream, List>>' is not a subtype of type 'Query'

Future>> List1() async { var idList = _firestore .collection('users') .doc(user.uid) .collection("IDs"); var idListQuery = await idList.get(); var map = idListQuery.docs; for (int…
0
votes
1 answer

Flutter: querying firebase realtime database data list with streambuilder error

iam trying to show list of data using StreamBuilderbut when i run this code it give me an error: i am fallowing this youtube video and i am trying to show data list i need to do this using streambuilder DatabaseReference starCountRef = …
0
votes
1 answer

Flutter Stream builder throwing an Error of null and i cannot access current user using Doc()

this is the error msg i get from the consol ======== Exception caught by widgets library ======================================================= The following _CastError was thrown building StreamBuilder
REX2420
  • 1
  • 1
0
votes
1 answer

Placing a Firebase Stream in a method

When accessing data from Firebase a QuerySnapshot is commonly returned. Is there a way to wrap this method so instead of a QuerySnapshot the data can be cleaned so it will return, say, a List? Currently, I'm accessing my collection like…
enchance
  • 29,075
  • 35
  • 87
  • 127
0
votes
0 answers

Should I avoid nested Streambuilder?

I'm using Firestore and Streambuilder to get realtime datas. In my app, I faced the situation that need 5 nested Streambuilder. I'm wondering should I avoid nested Streambuilder? Is there any way better? In addition, this is my firestore collection…