diff --git a/docs/site/angular-auth-oidc-client/docs/documentation/public-api.md b/docs/site/angular-auth-oidc-client/docs/documentation/public-api.md index 6f8b9602..d2c69c90 100644 --- a/docs/site/angular-auth-oidc-client/docs/documentation/public-api.md +++ b/docs/site/angular-auth-oidc-client/docs/documentation/public-api.md @@ -101,6 +101,21 @@ this.userData$ = this.oidcSecurityService.userData$; } ``` +## userData + +A signal implementation of `userData$`. +The `userData` signal returns a `Signal`. + +### Example + +```ts +userData = this.oidcSecurityService.userData; + +console.log(this.userData().userData); +console.log(this.userData().userData?.name); +console.log(this.userData().allUserData); +``` + ## isAuthenticated$ The `isAuthenticated$` property returns an `Observable`. This object is filled depending on with how many configurations you run. The `AuthenticatedResult` is structured as follows: @@ -148,6 +163,20 @@ this.isAuthenticated$ = this.oidcSecurityService.isAuthenticated$; } ``` +## authenticated + +A signal implementation of `isAuthenticated$`. +The `authenticated` signal returns a `Signal`. + +### Example + +```ts +authenticated = this.oidcSecurityService.authenticated; + +console.log(authenticated().isAuthenticated); +console.log(authenticated().allConfigsAuthenticated); +``` + ## isLoading$ > The property is disabled and will be removed in future versions. Please use the `PublicEventsService` with the events `EventTypes.CheckingAuth`, `EventTypes.CheckingAuthFinished`, `EventTypes.CheckingAuthFinishedWithError` instead