Deploying 3 simple functions over firebase project to get started with and expecting their respective URLs after deploying but getting no url.
Here is the code:
const functions = require('firebase-functions');
// // Create and Deploy Your First Cloud Functions
// // https://firebase.google.com/docs/functions/write-firebase-functions
//
exports.helloWorldOne = functions.https.onRequest((request, response) => {
response.send("Hello 1 from Firebase!");
});
exports.helloWorldTwo = functions.https.onRequest((request, response) => {
response.send("Hello 2 from Firebase!");
});
exports.helloWorldThree = functions.https.onRequest((request, response) =>{
response.send("Hello 3 from Firebase!");
});
Output:
D:\IOT\DialogFlow\firebase functions>firebase deploy
=== Deploying to 'fir-functions-22d02'...
i deploying functions Running command: npm --prefix ./functions/ run lint
functions@ lint D:\IOT\DialogFlow\firebase functions\functions eslint .
- functions: Finished running predeploy script. i functions: ensuring necessary APIs are enabled...
functions: all necessary APIs are enabled i functions: preparing functions directory for uploading...
Deploy complete!
Please note that it can take up to 30 seconds for your updated functions to propagate. Project Console: https://console.firebase.google.com/project/fir-functions-22d02/overview
I have tried the following:
- Deleting "npm --prefix \"$RESOURCE_DIR\" run lint".
- Deleting complete "predeploy": [
"npm --prefix \"$RESOURCE_DIR\" run lint"
]
Replaced the code with following:
- {
"functions": {
"predeploy": [
"npm --prefix ./functions/ run lint"
"npm --prefix ./functions/ run build"
]
}
}
- {
"functions": {
"predeploy": [
"npm --prefix ./functions/ run lint"
]
}
}
None of them worked.