Search code examples
google-cloud-functionsfirebase-console

React Native Firebase: How do I add a function to Firebase Console?


I'm contributing to a React Native project that uses firebase-functions. In the Functions section of the Firebase Console there's a list of existing functions, and I want to know how to add a new one. I know what code I want to write, but I don't know how to deploy it to Firebase so that it will appear in this Functions section of the console. A tutorial I saw said to use firebase deploy, but when I do that within my project it says function 'firebase' not found. Is there another way to add the functions to the console?


Solution

  • When you deploy Cloud Functions through the Firebase CLI by running firebase deploy or firebase deploy --only functions, any successfully deployed functions automatically get added to the Firebase console.

    There is no separate step to get them added, nor any way to add Cloud Functions through the Firebase console. Just run firebase deploy and they will show up.