Ionic Weather uses Firebase Functions as a backend.
npm is the project's package manager.
npm i
Firebase Functions uses Node.js v16. Please use a node version manager tool like nvm to switch to the correct version.
A .runtimeconfig.json
file is necessary to provide the API secret keys.
concurrently runs firebase emulators:start
simultaneously with the build
command (with a --watch
flag to rebuild on code changes).
npm run dev
You can view the emulator logs by navigating to localhost:8001
.
esbuild compiles and minifies the Typescript code.
npm run build
Deploy runs the build
command and uploads the folder with the compiled code to Firebase. If the deploy is successful, each exported function will be assigned a generated (projectname-serverlocation-functionname
) link. Now, you can call the function by using that URL!
npm run deploy