Skip to content

Instantly share code, notes, and snippets.

Created Aug 19, 2022
What would you like to do?
Firestore in Cloud Functions
const {Firestore} = require('@google-cloud/firestore');
const firestore = new Firestore();
exports.helloWorld = async (req, res) => {
const document = firestore.doc('users/steren');
const doc = await document.get();
console.log('Read the document');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment