Skip to content
This repository has been archived by the owner on Mar 3, 2022. It is now read-only.

New TypeScript typings don't allow optionless UserManager #1017

Closed
ulrichb opened this issue Dec 18, 2019 · 2 comments · Fixed by #1018
Closed

New TypeScript typings don't allow optionless UserManager #1017

ulrichb opened this issue Dec 18, 2019 · 2 comments · Fixed by #1018
Labels
Milestone

Comments

@ulrichb
Copy link
Contributor

ulrichb commented Dec 18, 2019

Since 1.10 the following code ...

const userManager = new Oidc.UserManager({});
userManager.signinSilentCallback()
    .catch(e => { console.error("Error while handling silent signin", e); });

... compiles to ...

Argument of type '{}' is not assignable to parameter of type 'UserManagerSettings'.
Type '{}' is missing the following properties from type 'UserManagerSettings': authority, client_id

For the signinSilentCallback() it is not necessary to provide authority/client_id.
(See https://github.com/IdentityModel/oidc-client-js/blob/dev/samples/VanillaJS/public/identityserver-sample-silent.js.)

@brockallen
Copy link
Member

So then what's the fix? Send a PR, please?

@ulrichb
Copy link
Contributor Author

ulrichb commented Dec 18, 2019

=> #1018

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

Successfully merging a pull request may close this issue.

2 participants