okta / samples-js-angular

samples-js-angular
https://github.com/okta/samples-js-angular
Other
73 stars 149 forks source link

How do you implement the clientID #38

Closed charlie39 closed 5 years ago

charlie39 commented 5 years ago

I am trying to use okta hosted login authentication. Suppose my clientID is 'hdjdk688hSsn'

should I put it like this: clientId: 'hdjdk688hSsn'

or like this within curly braces as shown in examples in the site:

clientId: '{cliendaiD}' I.e. clientId: '{hdjdk688hSsn}' ?

krzysio94598 commented 5 years ago

Do Not use curly braces.

charlie39 commented 5 years ago

Thanks. i was getting an error 'invalid client id' because i mistyped my clientid. Changed it to the correct one and tried again, still gave me the error, from the okta dashboard system log it showed my web was still sending the earlier wrong clientid. I was confused. Then i realized that i completely forgot the fact that i had used service worker in my angular pwa and it was caching all the of it. Took sometime to realize it and deleted the cache once. Now it's working perfectly. Just letting putting it out for others in case if anybody had face this situation.