I am getting the following error when executing the command firebase deploy --only function in my Ionic 3 project. This solution is not working for me.
In my case I just removed stub type from my packege.json and it started working for me updating just everything was not working, because this old shit is not compatable with the newer version of firebase well you didnt mentioned in your question that you do have this in your dependencies but I am 100% sure the problem is coming from here, because I just spent a whole night because of this:
"dependencies": {
"@types/firebase": "^3.2.1", <<====== this is shit man
"@types/fs-extra": "^8.0.1",
"@types/mongoose": "^5.5.43",
"@types/request": "^2.48.4",
"actions-on-google": "^2.12.0",
"bcrypt-inzi": "^1.0.7",
"body-parser": "^1.18.3",
"dialogflow-fulfillment": "^0.6.1",
"express": "^4.17.1",
"firebase-admin": "^8.6.0",
"firebase-functions": "^3.3.0",
"fs-extra": "^8.1.0",
"mongoose": "^5.8.9",
"request": "^2.88.0"
},
have you noticed this warning when running npm i
npm WARN deprecated @types/firebase@3.2.1: This is a stub types definition for Firebase API (https://www.firebase.com/docs/javascript/firebase). Firebase API provides its own type definitions, so you don't need @types/firebase installed!
since firebase functions have its own typing file it is not required at all now