Reputation: 386
I have a bunch of HTML files on my website (blogs). Instead of adding in the nav, header, footer, etc. I just want to call a function that will make a GET request to the HTML file and add in the header and footer. The issue with this is I can't find anywhere how I make a GET request to a file through a firebase function.
Upvotes: 0
Views: 761
Reputation: 599956
Cloud Functions are essentially just tiny node scripts that run in response to external events, or an external HTTPS trigger. So you can just use the regular node ways of making a HTTP request, typically with the built in http
module or the request
library.
Some links:
Upvotes: 2