Skip to content

Conversation

Langers8
Copy link
Contributor

@Langers8 Langers8 commented Dec 2, 2021

Add client-side location selection for callable functions.

Allow App functions to call Cloud Functions with a selectable Region (Android & iOS) or Custom Domain (iOS only); e.g. functions created for region "europe-west2".

Otherwise, all Firebase Functions calls are to the default "us-central1" region.

Allows client-side Functions calls to remote functions using a supported 
Region (Android & iOS) or Custom Domain (iOS only).

See 
https://firebase.google.com/docs/functions/locations#client-side_location_selection_for_callable_functions

Adds a method to FirebaseApp ('functions') to set Region or 
CustomDomain. 

Example usage: firebase().app().functions("europe-west")

See 
https://firebase.google.com/docs/reference/node/firebase.app.App#functions

Example client-side call:
firebase().functions().httpsCallable('functionName')()
calls Cloud Function:
exports functionName = functions.region('europe-west1')...
See 
https://firebase.google.com/docs/functions/locations#best_practices_for_changing_region

Supported regions: See 
https://firebase.google.com/docs/functions/locations

By default functions run in the "us-central1" region, unless another 
region is selected.

Android Functions Emulator: Set 'localhost' host to 10.0.2.2
@cla-bot
Copy link

cla-bot bot commented Dec 2, 2021

Thank you for your pull request and welcome to our community. We require contributors to sign our Contributor License Agreement, and we don't seem to have you on file. In order for us to review and merge your code, please sign the CLA at https://www.nativescript.org/cla.
CLA has not been signed by users: @Langers8.
After signing the CLA, you can ask me to recheck this PR by posting @cla-bot check as a comment to the PR.

@Langers8
Copy link
Contributor Author

Langers8 commented Dec 2, 2021

@cla-bot check

@cla-bot cla-bot bot added the cla: yes label Dec 2, 2021
@cla-bot
Copy link

cla-bot bot commented Dec 2, 2021

The cla-bot has been summoned, and re-checked this pull request!

@triniwiz triniwiz merged commit b01b075 into NativeScript:main Dec 31, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants