cancel
Showing results for 
Search instead for 
Did you mean: 

How to use onGigyaServiceReady() ?

0 Kudos

In our Ui5 application, we are using Gigya Screensets in different controllers. As per the Gigya documentation available, we are to declare all gigya related functions in one handler and call it in onGigyaServiceReady().
We are calling the Gigya WebSDK in index.html file.

Are we supposed to declare all the functions having Gigya API Calls in onGigyaServiceReady function? If not, then how do we ensure that all Gigya APIs are executed once the Gigya WebSDK is loaded.

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member629536
Participant

Hi Abhishek,

"Are we supposed to declare all the functions having Gigya API Calls in onGigyaServiceReady function?

Yes, this will ensure you don't come across the "Uncaught ReferenceError: gigya is not defined" error.
In order for Gigya API calls to function correctly you need to ensure the Gigya Web SDK is loaded before making the calls.

Using onGigyaServiceReady allows you to do this.

My Example below

var onGigyaServiceReady = function () {    
        gigya.accounts.showScreenSet({
          screenSet: screensetID + "-RegistrationLogin"        
        });   
  };

regards

Ibrahim