Skip to content
This repository has been archived by the owner on Jan 26, 2025. It is now read-only.

okta-angular missing type for return of getAccessToken() in TypeScript #75

Closed
th3n3wguy opened this issue Dec 14, 2017 · 3 comments
Closed

Comments

@th3n3wguy
Copy link

Issue:

Within the okta-angular package, the typing output for the Okta Service's .getAccessToken() function return value is declared as any. This causes an issue when attempting to retrieve the access token using the .accessToken property on the object that is returned. After a quick search through the repository, it appears that the reason this is occurring is due to the fact that the return type is missing on the getAccessToken() function definition located on this line of code.

Possible Resolution

Need to define either an interface or a class that will contain the definition for the token than is returned from the @okta/okta-auth-js function definition for then token and set that as the type for the return value of the function. If I get a chance, I will attempt to create this pull request, but please don't count on it.

@robertjd
Copy link
Contributor

robertjd commented Dec 15, 2017

Hi @th3n3wguy , thank you for the report. We'll take a look at this next week

@cmckni3
Copy link

cmckni3 commented Feb 1, 2018

In general, types need to be added for TypeScript. I noticed a lot of any "types" in the type definitions. I can contribute if I have time.

@jmelberg-okta
Copy link
Contributor

Resolved with #157 and #167

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants