Success Callback and Error Callback

Hi everyone,
I’m experiencing issue in the function renderEl success callback and error callback. I’m using the JS Okta Plugin (https://ok1static.oktacdn.com/assets/js/sdk/okta-signin-widget/2.16.0/js/okta-sign-in.min.js).

The goal is to use these callbacks for tracking successfull login. Here’s my code :

function widgetSuccessCallback(res) { console.log('sucess'); }
function widgetErrorCallback(err) { console.log('error'); }
signIn.renderEl({ el: '#okta-container' }, widgetSuccessCallback, widgetErrorCallback);

The functions widgetSuccessCallback and widgetErrorCallback are never called. Is there a way to add some scripts if login succeed or fail ?

Regards,