Firestore
conceptual
Firestore is a noSQL database that is most similar to MongoDB. It's made of collections and documents.
A collection is a set of documents
A document is a set of fields. A document may contain 20k fields and 2 megabytes of data.
A reference serves to identify a tentative collection or a tentative document. They are tentative because the reference on its own does not guarantee the existence of what it is referring to.
references and release notes
- client SDK reference
- admin SDK reference - table of content
- admin SDK reference - googleapis
- admin SDK reference - cloud.google.com
import paths and init
"firebase/firestore" // client SDK
"firebase/firestore/lite" // client SDK
"firebase-admin/firestore" // admin SDK
We init a db object with the config, for use in firestore-related functions.
const db = getFirestore(app)