Skip to content

Latest commit

 

History

History
25 lines (14 loc) · 1.58 KB

File metadata and controls

25 lines (14 loc) · 1.58 KB

Your Firebase-Flutter setup is finished, and you're ready to start building your app!

You'll start by setting up Cloud Firestore and initializing it with some values.

  1. Open the Firebase console, then select the Firebase project that you created during setup.

  2. From the left nav Develop section, select Database.

  3. In the Cloud Firestore pane, click Create database.

  4. In the Security rules for Cloud Firestore dialog, select Start in test mode, then click Enable. (Test mode allows any user to read and write to your database, which is convenient during development. However, this can be a security risk. Before releasing any app to production, you should add security rules.) Our database will have one collection, that we'll name "words". In the collection is where the words and isFavorite flag are stored.

  5. Click Add Collection, set the collection's name to words, then click Next. You can now add documents to your collection. Each document has a Document ID, and we'll need to have word and isFavorite fields.

  6. Enter a word using CamelCase letters. For example TestPair.

  7. For the existing Field, enter the value of word, select string for the Type, then enter the Value of TestPair.

  8. Click the Add Field icon to add a second field to contain the isFavorite flag. Select boolean for the Type, then initialize the Value as true.

  9. Click Save.

  10. Add 10 more word pairs by clicking Add Document.