I followed the following steps:
The Firebase CLI (Command Line Interface) requires Node.js and npm, which you can install by following the instructions on https://nodejs.org/
- Installing Node.js also installs npm
Once you have Node.js and npm installed, install the Firebase CLI via npm:
npm install -g firebase-tools- This installs the globally available firebase command. To update to the latest version, re-run the same command
Initialize your project:
a. Runfirebase loginto log in via the browser and authenticate the firebase tool.b.Go to your Firebase project directory or create the directory
c. Run firebase init functions
- The tool gives you an option to install dependencies with npm. It is safe to decline if you want to manage dependencies in another way.
Select associated firebase project
Select
Yto install dependencies with npmMove to directory setup firebase functions
Edit
index.jsfile with the function you createdRun the
firebase use --addto add your Firebase projectRun
firebase deploy --only functionsto deploy the function
After all this I get the message in the terminal at deploy was completed but in the Firebase console, when i click on Functions tab there are no functions listed!?
