Skip to content

Instantly share code, notes, and snippets.

@bacongravy
Last active June 8, 2020 04:07
Show Gist options
  • Select an option

  • Save bacongravy/c421bcf996af7ac80010439ab55354ce to your computer and use it in GitHub Desktop.

Select an option

Save bacongravy/c421bcf996af7ac80010439ab55354ce to your computer and use it in GitHub Desktop.
const credentials = JSON.parse(process.env.FIREBASE_SERVICE_ACCOUNT);
const { Firestore } = require("@google-cloud/firestore");
const db = new Firestore({ projectId: credentials.project_id, credentials });
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment