Questions tagged [flutter-streambuilder]
192 questions
0
votes
0 answers
StreamController don't update my component when a new value is added to it
I have a problem with my stream. I have a StreamController.broadcast() active in the project which is used on 2 different screens. And I have a listen method on this Stream so when the value stored in it changes, the component will update with the…

Mabel
- 1
- 3
0
votes
2 answers
Flutter stuck with a "DatabaseEvent subtype" error
The below code gives an error of subtype
Data Structure
code
StreamBuilder(
stream: _database.orderByKey().onValue,
builder: (context, snapshot) {
final valudisp = [];
if (snapshot.hasData) {
…

Buddy Ramesh
- 1
- 6
0
votes
1 answer
How can I fetch data from Firebase based on the selected date on calendar?
I have a calendar functions as food log where if user select a particular date on that calendar, it would show all the foods has been consumed only on that selected date.
My date field is in timestamp format like this January 1, 2022 at 12:00:00 AM…

jung_66
- 41
- 4
0
votes
1 answer
How to pull a data from firebase and use it for pulling another data to using it in StreamBuilder
I am trying to get all postID's of the currently logged in user from the left, and I want to use this information to get all posts which includes same postID. How can I achieve this?
So far I created a function that can pull all postID's of current…

Ulas Demir
- 27
- 3
0
votes
2 answers
How can I update Listview in Streambuilder in flutter
I have a streambuidler widget that contains a listview to display whom the current user has recently chatted with. When the current user receives a message that message should be pushed to the top of the listview, however that message is always…

Leo Tran
- 37
- 5
0
votes
0 answers
Flutter Firebase How To Merge Streams List and Display on StreamBuilder with Single a Stream
I have a combine list of streams like that;
var Ref1 = _firestore
.collectionGroup("Posts")
.where('postID', whereIn: List1)
.snapshots();
var Ref2 = _firestore
.collectionGroup("Posts")
.where('postID', whereIn:…

Rkdio
- 153
- 2
- 13
0
votes
1 answer
how to stream my data from supabase to the flutter app
I'm trying to stream a tables data into my flutter app, but I keep getting some errors.
I'm trying to do it as I would do it with Firebase but with no success :(
Can someone point out what is it that I'm doing wrong here?
My db:
My service:
import…

NiiTii
- 237
- 6
- 25
0
votes
1 answer
Countdown timer date and time format in Flutter
I'm making a Countdown timer, but the problem is, how can I make it realize the difference from AM to PM if it is a 24h clock? For instance, I have put the wakeUpTime inside the code to be tomorrow morning at 10. And if the time I'm asking this…

GrandMagus
- 600
- 3
- 12
- 37
0
votes
1 answer
Flutter stream: Stream builder returns Null value
I'm trying to get data from Firestore via a stream, but it's returning null.
This is the code of my model.
class UserData {
String? uid;
String? name;
String? sugar;
int? strength;
UserData(
{required this.uid,
required…

Ahmad Raza
- 758
- 7
- 26
0
votes
0 answers
I am passing some items to a page, the first time the page loads, the items appear but after switching and coming back, nothing appears on the page
Any help will be useful. I am using StreamBuilder to load items to a page, the first time I open the page, the products appear but after navigating to another page and navigate back to the same page, nothing appears. Here is my code:
The UI…
0
votes
1 answer
Flutter Firebase The method 'data' was called on null
I'm using Firestore and I tried to get streams by Streambuilder.
However, This error happened.
The following NoSuchMethodError was thrown building StreamBuilder>
(dirty, state:…

flyer
- 29
- 3
0
votes
1 answer
Flutter Firebase async query not retrieving data inside a stream function
I am trying to query a User from firebase within another query but for some reason but I can't get the code to work
The function the wont run is await usersRef.doc(uid).get(); and can be found here:
static getUserData(String uid) async {
return…

RyanBuss01
- 203
- 1
- 11
0
votes
0 answers
StreamBuilder infinite loading
when I rebuild a widget which is an ancestor of another widget that contains StreamBuilder class, the last one is loading forever.
I am posting a simple example:
This build method is the Ancestor widget, a stateful widget.
The _buildForm method…

blob
- 439
- 8
- 21
0
votes
0 answers
Can we use stream in flutter for assigning data to Class variables (not mapping data into widget)
This is my UerModel Class, and i have to load data into class variables. And also want to auto fetch each time on any update. that's why i use Streams, but it does not allow, as I have to return a widget.
class UserModel {
late String name;
…
0
votes
1 answer
Flutter snapshots from one StreamBuilder is showing in another StreamBuilder
I have two collections ('stream1', 'stream2') from firestore and I want them to render to the screen using a StreamBuilder and a ListView. I have 2 buttons that I use to switch between ListViews. But I'm getting an error that says Bad state: field…

Sev
- 31
- 1
- 8