Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Firestore

 Firestore

Cheesecake Labs

June 10, 2019
Tweet

More Decks by Cheesecake Labs

Other Decks in Technology

Transcript

  1. Firestore Flexible, scalable NoSQL cloud database to store and sync

    data for client- and server-side development.
  2. Flexibility Store your data into documents that contain fields mapping

    to values. These documents are stored in collections, which are containers for your documents that you can use to organize your data and build queries.
  3. Expressive querying You can use queries to retrieve individual, specific

    documents or to retrieve all the documents in a collection that match your query parameters. Your query can include multiple, chained filters and combine filtering and sorting. They are also indexed by default, so query performance is proportional to the size of your result set, not your data set.
  4. Realtime updates Cloud Firestore uses data synchronization to update data

    on any connected device. However, it's also designed to make simple, one-time fetch queries efficiently.
  5. Offline support Cloud Firestore caches data that your app is

    actively using, so the app can write, read, listen to, and query data even if the device is offline. When the device comes back online, Cloud Firestore synchronizes any local changes back to Cloud Firestore.
  6. Each document contains a set of key-value pairs. Cloud Firestore

    is optimized for storing large collections of small documents. All documents must be stored in collections. Documents can contain subcollections and nested objects, both of which can include primitive fields like strings or complex objects like lists. Documents
  7. set( ) When you use set( ) to create a

    document, you must specify and ID for the document to create.
  8. add( ) If there isn't a meaningful ID for the

    document, it can be auto-generated.
  9. doc( ) You can also create a document reference with

    an auto-generated ID, then use the reference later.