keycloak-angular 9.3.0 → 10.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md
CHANGED
|
@@ -53,12 +53,13 @@ Note that `keycloak-js` is a peer dependency of Keycloak Angular. This change al
|
|
|
53
53
|
|
|
54
54
|
| Angular | keycloak-angular | keycloak-js | Support |
|
|
55
55
|
| :---------: | :--------------: | :---------: | :-----------------: |
|
|
56
|
-
| 13.x |
|
|
56
|
+
| 13.x | 10.x.x | 18 | Bugs / New Features |
|
|
57
|
+
| 13.x | 9.x.x | 10 - 17 | Bugs |
|
|
57
58
|
| 11.x - 12.x | 8.4.0 | 10 - 15 | None |
|
|
58
59
|
|
|
59
60
|
Only the latest version of Angular in the table above is actively supported. This is due to the fact that compilation of Angular libraries is [incompatible between major versions](https://angular.io/guide/creating-libraries#ensuring-library-version-compatibility).
|
|
60
61
|
|
|
61
|
-
_Note_:
|
|
62
|
+
_Note_: Only for keycloak-angular **v.9**, there is the need to add `allowSyntheticDefaultImports: true` in the tsconfig.json file in your project. This is related to this [issue in the keycloak project](https://github.com/keycloak/keycloak/issues/9045). From keycloak-angular v.10 on, there is no need to set this configuration.
|
|
62
63
|
|
|
63
64
|
#### Choosing the right keycloak-js version
|
|
64
65
|
|
|
@@ -83,7 +84,7 @@ function initializeKeycloak(keycloak: KeycloakService) {
|
|
|
83
84
|
return () =>
|
|
84
85
|
keycloak.init({
|
|
85
86
|
config: {
|
|
86
|
-
url: 'http://localhost:8080
|
|
87
|
+
url: 'http://localhost:8080',
|
|
87
88
|
realm: 'your-realm',
|
|
88
89
|
clientId: 'your-client-id'
|
|
89
90
|
},
|
|
@@ -221,7 +222,7 @@ In the example below, any http requests with the header `token-update: false` wi
|
|
|
221
222
|
```ts
|
|
222
223
|
await keycloak.init({
|
|
223
224
|
config: {
|
|
224
|
-
url: 'http://localhost:8080
|
|
225
|
+
url: 'http://localhost:8080',
|
|
225
226
|
realm: 'your-realm',
|
|
226
227
|
clientId: 'your-client-id'
|
|
227
228
|
},
|
|
@@ -258,8 +259,8 @@ keycloakService.keycloakEvents$.subscribe({
|
|
|
258
259
|
<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->
|
|
259
260
|
|
|
260
261
|
<!-- prettier-ignore -->
|
|
261
|
-
|[<img src="https://avatars3.githubusercontent.com/u/676270?v=4" width="89px;"/><br /><sub><b>Mauricio
|
|
262
|
-
| :---: | :---: |
|
|
262
|
+
|[<img src="https://avatars3.githubusercontent.com/u/676270?v=4" width="89px;"/><br /><sub><b>Mauricio Vigolo</b></sub>](https://github.com/mauriciovigolo)<br />|[<img src="https://avatars1.githubusercontent.com/u/695720?s=400&v=4" width="89px;"/><br /><sub><b>Jon Koops</b></sub>](https://github.com/https://github.com/jonkoops)<br />|
|
|
263
|
+
| :---: | :---: |
|
|
263
264
|
|
|
264
265
|
<!-- ALL-CONTRIBUTORS-LIST:END -->
|
|
265
266
|
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { HttpHeaders, HttpRequest } from '@angular/common/http';
|
|
2
2
|
import { Subject } from 'rxjs';
|
|
3
|
-
import Keycloak from 'keycloak-js';
|
|
4
3
|
import { ExcludedUrlRegex, KeycloakOptions } from '../interfaces/keycloak-options';
|
|
5
4
|
import { KeycloakEvent } from '../interfaces/keycloak-event';
|
|
6
5
|
import * as i0 from "@angular/core";
|
|
@@ -29,7 +28,7 @@ export declare class KeycloakService {
|
|
|
29
28
|
isLoggedIn(): Promise<boolean>;
|
|
30
29
|
isTokenExpired(minValidity?: number): boolean;
|
|
31
30
|
updateToken(): Promise<boolean>;
|
|
32
|
-
loadUserProfile(forceReload?: boolean): Promise<
|
|
31
|
+
loadUserProfile(forceReload?: boolean): Promise<import("keycloak-js").KeycloakProfile>;
|
|
33
32
|
getToken(): Promise<string>;
|
|
34
33
|
getUsername(): string;
|
|
35
34
|
clearToken(): void;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "keycloak-angular",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "10.0.0",
|
|
4
4
|
"description": "Easy Keycloak setup for Angular applications",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"@angular/common": "^13",
|
|
30
30
|
"@angular/core": "^13",
|
|
31
31
|
"@angular/router": "^13",
|
|
32
|
-
"keycloak-js": "^
|
|
32
|
+
"keycloak-js": "^18"
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
35
|
"tslib": "^2.3.0"
|