Answer the question
In order to leave comments, you need to log in
What is the difference between firebase module and firebase-admin in nodejs?
All the best!
Faced with the need to get data from firebase using nodejs, and here it’s somehow not entirely clear to me which npm module / package is best to use. The npm website seems to have a firebase module , and in the example it says that for the robots you need to call firebase = require('firebase') although in the firebase docks I almost see admin = require('firebase-admin'); So I don't understand what the difference is and how to work with it correctly.
I only need to get data by key
Answer the question
In order to leave comments, you need to log in
You open the module page and read:
firebase :
This SDK is intended for end-user client access from environments such as the Web, mobile Web (eg React Native, Ionic), Node.js desktop (eg Electron), or IoT devices running Node.js. If you are instead interested in using a Node.js SDK which grants you admin access from a privileged environment (like a server), you should use the Firebase Admin Node.js SDK.
The Firebase Admin Node.js SDK enables access to Firebase services from privileged environments (such as servers or cloud) in Node.js.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question