Using Firestore as a backend to your Flutter app

  Рет қаралды 523,002

Google for Developers

Google for Developers

Күн бұрын

The Firebase Cloud FireStore is a fantastic way to put a backend on a Flutter app without the complexities of setting up a personal serverIn this video, Andrew walks through how to integrate a Cloud Firestore database from Firebase into a Flutter app. He also covers what kind of database Cloud Firestore is and how it can help you!
Flutter is Google’s mobile SDK for crafting high-quality native interfaces on iOS and Android in record time. Flutter works with existing code, is used by developers and organizations around the world, and is free and open source.
Chapters:
0:00 - What is Cloud FireStore?
1:40 - Setting up FireStore in console
2:00 - Register the individual apps for your project
5:21 - Open underlying xcode project
8:25 - Base the item count off the number of FireStore documents
10:20 - firestore to run a transaction
11:06 - Recap
Get started with Flutter → flutter.io
Try the Firebase for Flutter codelab → bit.ly/2JdRFIz
Join the conversation → bit.ly/2kPWIA7
Subscribe to Google for Developers → goo.gle/developers
#Flutter #Firebase

Пікірлер: 247
@jungeunwoo6905
@jungeunwoo6905 5 жыл бұрын
Compact with exactly useful information. The most professional flutter tutorial video I've seen so far. Thank you.
@LadislavSzolik
@LadislavSzolik 3 жыл бұрын
Thanks Andrew! That it very useful! I need to say, you got a natural and friendly voice to explain!
@therealwtpieh5300
@therealwtpieh5300 7 ай бұрын
This was really cool! The like button lights up when he gets to the part where he talks about the db updating in response to UI events!
@smokedsalmon935
@smokedsalmon935 6 жыл бұрын
I feel like this was published just for me in the right time... hahaha
@gvcallen
@gvcallen 4 жыл бұрын
Honestly a really amazing video. Very thorough, informative and somehow condensed into a 12 minute video. Thanks a lot
@faheemahmad3957
@faheemahmad3957 6 ай бұрын
this was awesome!! please make more like these and go indepth
@vedmodikauratg1865
@vedmodikauratg1865 2 жыл бұрын
this covers all I need to know in less than 12 minutes. what a video.
@sexyeur
@sexyeur 4 жыл бұрын
Thank you Google and Andrew Brogdon!
@AvinashSingh-nq5ud
@AvinashSingh-nq5ud 6 жыл бұрын
Thanks, Andrew sir, Please keep coming with more videos
@user-ph5zu8wc3i
@user-ph5zu8wc3i Жыл бұрын
Thank you so so much It's so clear that can understand how connect to database and write data just following. Thank you for serving this amazing dart language and flutter developers.
@WholeNewLevel2018
@WholeNewLevel2018 6 жыл бұрын
I like illustrative video, awesome explanation great job,
@theethicalh3707
@theethicalh3707 4 жыл бұрын
Oooooooooooooooooooh my good that's exactly what i was searching for thaaank you so much google i looooooove you man
@davidweiss5249
@davidweiss5249 5 жыл бұрын
Note that you should use the console to edit the Database.Rules to avoid a PERMISSION error on the android app; change "allow read, write: if false;" to "allow read, write: if true;"
@jacqueskroese9806
@jacqueskroese9806 4 жыл бұрын
Thank you so much! Great content
@jasonsebring3983
@jasonsebring3983 5 жыл бұрын
There really is a ton of work being done for you here. I normally would have to setup a socket server and a way to sync things together upon fresh load etc etc. I wonder about buffering when say there are 10000 things going on at once meaning say you were showing popular posts in a feed that were showing meta items like votes and chat counts etc.
@hippolytesama3817
@hippolytesama3817 3 жыл бұрын
Really thanks, that was awesome and pretty clear
@ici6308
@ici6308 4 жыл бұрын
Just wonderful !
@lordeloalvaro
@lordeloalvaro 5 жыл бұрын
I've start using flutter, though it's very hard to find a good example of how to, There're lot of videos I'd like to have just a doc that explains every widget. Thanks for the video tutorial and great job
@lordeloalvaro
@lordeloalvaro 5 жыл бұрын
I've some few questions about flutter like MVC pattern, an authentication default process(that's common on other frameworks), localization default pattern...flutter has a great variability of widgets, though to turn itself in a complete solution it needs a little more effort, it's on the right path. Thanks for your reply, & have a nice life.
@kimanoir1136
@kimanoir1136 3 жыл бұрын
THIS MAN KNOWS WHAT HE'S DOING
@aladdinaouimeur2649
@aladdinaouimeur2649 5 жыл бұрын
*GREAT JOB YOU GUYS ARE THE BEST*
@Mohammadoudat
@Mohammadoudat 2 жыл бұрын
Thank you for your infromative tutorial. However, we are in 2021 and too much updates applied on Flutter and Dart. Therefore, we need a 2021 videos. Appretiate the help.
@MichaelDuarte
@MichaelDuarte 4 жыл бұрын
Its amazing how simple this was to implement.
@michaelessiet5172
@michaelessiet5172 3 жыл бұрын
This looks surprisingly easy
@claudedaiga5897
@claudedaiga5897 5 жыл бұрын
So well explained!
@mohammedsalman3397
@mohammedsalman3397 5 жыл бұрын
Great video, thanks!
@Trancecend
@Trancecend 5 жыл бұрын
Good tutorial. I would have mentioned, however, that the iOS step for adding the Pod dependency SHOULD be skipped, instead of not mentioning it at all. But still good, I got started pretty quickly.
@JoshuaRoy
@JoshuaRoy 6 жыл бұрын
They put the iOS screenshot on the pixel...
@isaacfrimpong9022
@isaacfrimpong9022 4 жыл бұрын
I find it very helpful.
@d-apps2699
@d-apps2699 5 жыл бұрын
I loved this guide, please more tutorials about flutter + firebase o/
@gersonricardotoribioossio9720
@gersonricardotoribioossio9720 4 жыл бұрын
Amazing and a really good explanation. It works to me. I think the documentation in firebase is not up to date because I couldn't be able to run firebase in my flutter app, a lot of problem in gradle file.
@dionplant9197
@dionplant9197 4 жыл бұрын
try this in -> gradle.properties add: android.useAndroidX=true android.enableJetifier in -> app/build.gradle change: minSdkVersion from 16 to 21 add: dependancies implementation 'androidx.multidex:multidex:2.0.0'
@SopheakVatt
@SopheakVatt 6 жыл бұрын
I'd love to see this kind of video.
@GoingWalkabout
@GoingWalkabout 5 жыл бұрын
Very useful, I'm evaluation to move my iOS app using Firestore to Flutter so I don't need to build a native Android app.
@brandonpillay9025
@brandonpillay9025 4 жыл бұрын
This is really great stuff
@kamranyusifov7451
@kamranyusifov7451 3 жыл бұрын
This is good. But please update the codelab to the recent changes, like the firebase core requirement.
@user-or7ji5hv8y
@user-or7ji5hv8y 5 жыл бұрын
Super useful video!
@GideonvanderMerwe
@GideonvanderMerwe 4 жыл бұрын
Hey Andrew, thanks for the awesome video. I have a question. Let's say you log in with firebase and pull some data down e.g. your latest band votes/results. Now lets say you close the app completely, even from the background. Then you open it again with no internet. Will it still use the last data pulled from firestore, or will it use the default values that you demonstrated? Thanks
@ammardorea1835
@ammardorea1835 4 жыл бұрын
Hey, Thank you very helpful video, I have question is this was an UI kit mobile app?
@mouttafiqimane7346
@mouttafiqimane7346 5 жыл бұрын
thank u for this tuto i want to ask you how can i get a stream from a specific user
@vapnex
@vapnex 6 жыл бұрын
*Glowing Green Screen*
@chstr0ng
@chstr0ng 3 жыл бұрын
Could we get some content on how to unit test and mock firestore? It's really hard to unit test streams and no information anywhere.
@ismaelalexandermalcacastro9990
@ismaelalexandermalcacastro9990 5 жыл бұрын
beautiful !!!!
@anthonygabriana3943
@anthonygabriana3943 4 жыл бұрын
When you install the google-services.plst for ios make sure to install it by opening the project in xcode and right clicking on the Runner Folder and using add file to add the google services file. Otherwise if you drag and drop it in your editor like intellij for some reason it makes the app freakout and create a bunch of errors. Took me 7 hours of trouble shooting to figure out that this was all I needed to do.
@rahmanatiqur2332
@rahmanatiqur2332 6 жыл бұрын
Thanks
@gokulakrishnan1977
@gokulakrishnan1977 4 жыл бұрын
Andrew Brogdon: 10:04 Me: Yeah I Know... I Know...
@wdavis6254
@wdavis6254 4 жыл бұрын
Yes sometimes i come down here to see how many developers are using flatter
@alexrom2662
@alexrom2662 4 жыл бұрын
Thanks a lot
@harjitsingh7308
@harjitsingh7308 6 жыл бұрын
Ive started to use firestore but lets say for some reason i have to switch to somethinf different in the future. Will this process be easy?
@ameen_was_here4958
@ameen_was_here4958 6 жыл бұрын
I am aware that firestore is in beta. But if i were to use it in production in one of my apps, Will firebase team notify devs about breaking changes before they were made Please reply
@redbrogdon
@redbrogdon 6 жыл бұрын
I'm not on the Firebase team (so I can't speak for them), but I'd be *extremely* surprised if that weren't the case. You can always try posting on their discussion forum just to be sure, though: groups.google.com/forum/#!forum/firebase-talk
@forestlaw89
@forestlaw89 5 жыл бұрын
They have been warning people about the changes in Firestore. For example, the change of dates to Timestamps
@baimamboukar4492
@baimamboukar4492 4 жыл бұрын
coool! Can we have a tutorial talking about AndroidX Migration? I have serious troubleshooting
@123superatom
@123superatom 5 жыл бұрын
if u can show an example using firestore with add,delete and update data in flutter, its will be more usefull
@raghav4296
@raghav4296 5 жыл бұрын
#askflutter Hi Andrew, a noob question - With respect to Firebase client SDKs, we have android and iOS but not specifically for Flutter and I assume we need to download both for working with Flutter? In terms of the whole array of features that Firebase and suite of integration it offers, is it safe to assume that all firebase features available if we were to write only android/iOS using their respective client SDKs be available in Flutter as well (or) are there any constraints that we need to be aware of? Thank you 😊
@niteeshmahato1596
@niteeshmahato1596 4 жыл бұрын
when a new document is added, snapshot fetches all the documents including the new one or only the newly added one ?
@somenathchakraborty2403
@somenathchakraborty2403 5 жыл бұрын
Thanks... :)
@letslearncomputerprogramming
@letslearncomputerprogramming 5 жыл бұрын
What is best for android or flutter in future?
@erlangparasu6339
@erlangparasu6339 3 жыл бұрын
please provide more tutorial about the security / permission of accessing the data
@aDifferentJT
@aDifferentJT 6 жыл бұрын
So your atomic operation can be async?
@RaitonGG
@RaitonGG 5 жыл бұрын
what about youtuber api? any vídeo on it?
@itkamsan349
@itkamsan349 4 жыл бұрын
Could you make a video how to join collections?
@myname5667
@myname5667 3 жыл бұрын
If transactions are made to prevent race conditions, why can't you use them when you are offline / what do you do when two clients edit the same field of one document and you want to merge the changes (i.e. if the field is a list)
@EmreYavuzalp
@EmreYavuzalp 3 жыл бұрын
I wish you showed us the whole code, it doesn't work. And it gives a load of errors.
@DDOCTORGaming
@DDOCTORGaming 2 жыл бұрын
Hi, by any chance do you have a video which you can link me to, that tackles the function of reading out-loud data fetched from Firestore as audio to user? Thanks
@rezamohebbi2692
@rezamohebbi2692 4 жыл бұрын
hi guys . is there a tutorial out there about how to set custom claims / role based auth / rolebased access contorll in flutter using firebase?
@nicorobin7666
@nicorobin7666 5 жыл бұрын
I searched the whole internet but could not find a single lesson on how to connect flutter and dart to mysql on phpmyadmin (not local host, its hosted on a server) or how to implement CRUD operations, please do some lessons for us, thank you so much
@ThomasLock
@ThomasLock 5 жыл бұрын
You wouldn't want to directly connect over MySQL. You need to create a REST API to do this.
@spidey5324
@spidey5324 4 жыл бұрын
I can use flutter and firebase in my androids and ios while on web I use React and firebase? Thanks.
@redsool1
@redsool1 6 жыл бұрын
Is there a convinient way to transfer firebase project from one google acc to another?
@kukuhdrawable6449
@kukuhdrawable6449 4 жыл бұрын
Hi i had error with gradle task assembledebug failed with exit code 1 Can you help me
@zafana1
@zafana1 4 жыл бұрын
I've set this up but it wasn't so straightforward and took a lot of time... different versions of the plugins were incompatible and project settings needed to be modified for both Android and iOS.
@MeetPatel-ku8bk
@MeetPatel-ku8bk 4 жыл бұрын
I am getting error for iOS xcode build - cloud_firestore/CloudFireStorePlugin.h not found
@chasingdownchano
@chasingdownchano 5 жыл бұрын
Is there a place I could find the code used in this video? A github link or something?
@DK-qz9ui
@DK-qz9ui 5 жыл бұрын
If there are lots of documents in collection, stream builder is very slow. Isn't it?
@bijayshrestha5820
@bijayshrestha5820 4 жыл бұрын
i got an error that "subproject has been already used in build script" how to resolve it??
@cachardiary
@cachardiary 6 жыл бұрын
nice video
@toobarahat4456
@toobarahat4456 4 жыл бұрын
Can I use flutter to make a order delivery + customer loyalty app?
@TheBooban
@TheBooban 6 жыл бұрын
Do you have to choose between Firestore and the Realtime Database or can you have both?
@redbrogdon
@redbrogdon 6 жыл бұрын
You can indeed use both in the same app: firebase.google.com/docs/firestore/firestore-for-rtdb
@benton202
@benton202 5 жыл бұрын
Great!!!
@tanmayfuse1747
@tanmayfuse1747 5 жыл бұрын
Can u able to fetch document files containing images and text from Firestore and display in flutter app?
@marlonsubuyu2012
@marlonsubuyu2012 3 жыл бұрын
You have to upload the images to Firebase Storage, then you paste the Storage reference of each file in Cloud Firestore
@RazaviImran
@RazaviImran 2 жыл бұрын
Same question i have
@WayT0Aesthetic
@WayT0Aesthetic 4 жыл бұрын
Gradle problem when i try to use firebase.. fix this
@NuncNuncNuncNunc
@NuncNuncNuncNunc 5 жыл бұрын
Is the race condition eliminated? If multiple users initiate a transaction at the same time, won't they both update the same initial value? A ticketing or reservation system could end up double booking if this is the case. Are there any tutorials that show how to use cloud_firestore with firestore rules? As best as I can determine in flutter example code, request.auth.uid is not sent to the server.
@gowthamrajukongara
@gowthamrajukongara 5 жыл бұрын
Hi all please tell me which package contains tomap() and frommap() methods if possible give me link thanks.
@heshansandeepa9471
@heshansandeepa9471 Жыл бұрын
Impressive
@SureshKumarMajhi
@SureshKumarMajhi 5 жыл бұрын
Hi, in your code at the time of configure firestore you didn't use any kind of "firestore.settings()" the way it has been mentioned it here - pub.dartlang.org/packages/cloud_firestore#-example-tab- . Is it really require to mention this setting thing or not? I'm bit confused about this.
@metallitech
@metallitech 6 жыл бұрын
Can I use Firestore as a backend to my Wibblewobble app, with Zigizigah as the front end?
@blipblap614
@blipblap614 6 жыл бұрын
Only if you really really really wanna.
@urvashisharma7415
@urvashisharma7415 4 жыл бұрын
i didnt really follow why we changed the onTap function from a plain update to something else...could someone help me out on this please?
@fmnaq
@fmnaq 5 жыл бұрын
please is there a GitHub repository to this tutorial?
@brian-beeler
@brian-beeler 5 жыл бұрын
github.com/beelerb/flutter_firestore_example It's just the code the video starts and ends with but better than nothing and it works. Note the part about the pubspec.yaml file.
@BenHayat
@BenHayat 5 жыл бұрын
At 2:07 in the video, to register the flutter app in Firebase where Do I go to my Flutter solution to get that Android App name? The instructions I get from that help, I can't find the name. Where di you get "com.flutter.firebase.example.flutterfirebase" ?
@nazhif9042
@nazhif9042 5 жыл бұрын
2:56
@superstark8543
@superstark8543 4 жыл бұрын
If I was in a band, I have would have not thought this much at first place. And if I tried to think that much, I would have smashed my guitar out of frustration.
@MisterDibitybopty
@MisterDibitybopty 3 жыл бұрын
Every time the list gets updated, is that a read from the database from each item? So 10 items would be 10 reads? Seems far too costly to use firestore database if that's the case.
@elhamkeshavarzarshadi7451
@elhamkeshavarzarshadi7451 5 жыл бұрын
please make some videos about working with complex json
@andrewbrogdon558
@andrewbrogdon558 5 жыл бұрын
In the meantime, you might like our JSON parsing example: github.com/flutter/samples/tree/master/jsonexample
@vinceramcesoliveros6739
@vinceramcesoliveros6739 6 жыл бұрын
What about AngularDart/dart2js? Is the flutter team different from angulardart team?
@florianrohrauer8471
@florianrohrauer8471 5 жыл бұрын
But isn´t that solution of updating the data with a Transaction muchh slower than just changing the value as the first solution?
@bougieliu1649
@bougieliu1649 5 жыл бұрын
awesome
@g46psk
@g46psk 6 жыл бұрын
how can i listen to a single document by a given key rather than a whole collection?
@utkarshmehta4430
@utkarshmehta4430 4 жыл бұрын
Is it possible to stream mp4 or mkv video from url? In flutter
@kirill4531
@kirill4531 6 жыл бұрын
what's the difference between Firebase Real-time Database and Firebase Firestore?
@redbrogdon
@redbrogdon 6 жыл бұрын
The Firebase team has an article that can explain it way better than me. :) firebase.google.com/docs/database/rtdb-vs-firestore
@kirill4531
@kirill4531 6 жыл бұрын
Andrew Brogdon, that's what I like in Google - they foresee all my questions :) Thanks Andrew!
@abdullahnaveed4834
@abdullahnaveed4834 Жыл бұрын
best video
@geethma3590
@geethma3590 4 жыл бұрын
Hi, I want to know about Cloud firestore how to connect with flutter windows app, please help me, Thank you.
@Rafiq07
@Rafiq07 4 жыл бұрын
What about Google Cloud Datastore? Are there any examples of using that as a backend for Flutter projects?
@alandigital360
@alandigital360 5 жыл бұрын
Does not work on Android with cloud_firestore:, I need to add the version cloud_firestore: ^0.7.4 :(
@williammagic9773
@williammagic9773 4 жыл бұрын
Says cannot use firestore
@AminulIslam-ns5dy
@AminulIslam-ns5dy 3 жыл бұрын
Same problem me
@aladdinaouimeur2649
@aladdinaouimeur2649 5 жыл бұрын
How To make The vote add just once????
@s_ap
@s_ap 4 жыл бұрын
How will I add to Web app as well ?
I tried 5 Firebase alternatives
10:31
Fireship
Рет қаралды 763 М.
When to Use Keys - Flutter Widgets 101 Ep. 4
9:40
Google for Developers
Рет қаралды 498 М.
Василиса наняла личного массажиста 😂 #shorts
00:22
Денис Кукояка
Рет қаралды 10 МЛН
I CAN’T BELIEVE I LOST 😱
00:46
Topper Guild
Рет қаралды 86 МЛН
Final muy increíble 😱
00:46
Juan De Dios Pantoja 2
Рет қаралды 45 МЛН
Making An $85 Guitar Play Like A $1000 Guitar
15:48
Musora
Рет қаралды 2,5 МЛН
Flutter Firebase Setup for Power Users
12:59
Fireship
Рет қаралды 83 М.
What advice would you give a student developer?
1:37
Google for Developers
Рет қаралды 2,8 М.
Cloud Firestore Data Modeling (Google I/O'19)
40:37
Firebase
Рет қаралды 171 М.
Getting started with Firebase on Flutter - Firecasts
19:28
Firebase
Рет қаралды 174 М.
I built a $5 chat app with Pocketbase & Svelte. Will it scale?
13:34
Pragmatic State Management in Flutter (Google I/O'19)
33:25
Flutter
Рет қаралды 447 М.
The Firebase Realtime Database and Flutter - Firecasts
59:26
Firebase
Рет қаралды 82 М.
Keep it Simple, State: Architecture for Flutter Apps (DartConf 2018)
29:00
Google for Developers
Рет қаралды 186 М.
Choose a phone for your mom
0:20
ChooseGift
Рет қаралды 4,5 МЛН