You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
thank you for the great library. Unfortunately it not runs with a local ADFS 2016 in IE11. I've added ie-shim and isomorphic-fetch, but no success (in all other browsers it's running). This is the error:
/** IE10 and IE11 requires the following for NgClass support on SVG elements */
import 'classlist.js'; // Run npm install --save classlist.js.
/** IE10 and IE11 requires the following for the Reflect API. */
import 'core-js/es6/reflect';
/** Evergreen browsers require these. **/
// Used for reflect-metadata in JIT. If you use AOT (and only Angular decorators), you can remove.
import 'core-js/es7/reflect';
/**
Required to support Web Animations @angular/platform-browser/animations.
Needed for: All but Chrome, Firefox and Opera. http://caniuse.com/#feat=web-animation
**/
import 'web-animations-js'; // Run npm install --save web-animations-js.
Hi
thank you for the great library. Unfortunately it not runs with a local ADFS 2016 in IE11. I've added ie-shim and isomorphic-fetch, but no success (in all other browsers it's running). This is the error:
My package.json:
{ "name": "dotnet_angular", "version": "0.0.0", "license": "MIT", "scripts": { "ng": "ng", "start": "ng serve", "build": "ng build --extract-css", "build:ssr": "npm run build -- --app=ssr --output-hashing=media", "test": "ng test", "lint": "ng lint", "e2e": "ng e2e" }, "private": true, "dependencies": { "@angular-devkit/build-angular": "^0.7.2", "@angular-devkit/core": "^0.7.2", "@angular/animations": "6.1.0", "@angular/common": "6.1.0", "@angular/compiler": "6.1.0", "@angular/core": "6.1.0", "@angular/forms": "6.1.0", "@angular/http": "6.1.0", "@angular/platform-browser": "6.1.0", "@angular/platform-browser-dynamic": "6.1.0", "@angular/platform-server": "6.1.0", "@angular/router": "6.1.0", "@nguniversal/module-map-ngfactory-loader": "^6.0.0", "angular-auth-oidc-client": "6.0.5", "aspnet-prerendering": "^3.0.1", "bootstrap": "^4.1.3", "classlist.js": "^1.1.20150312", "core-js": "^2.5.7", "es6-promise": "^4.2.4", "ie-shim": "^0.1.0", "isomorphic-fetch": "^2.2.1", "rxjs": "^6.2.2", "web-animations-js": "^2.3.1", "zone.js": "^0.8.26" }, "devDependencies": { "@angular/cli": "^6.1.2", "@angular/compiler-cli": "6.1.0", "@angular/language-service": "6.1.0", "@types/jasmine": "~2.8.8", "@types/jasminewd2": "~2.0.3", "@types/node": "~10.5.5", "codelyzer": "^4.4.2", "jasmine-core": "~3.1.0", "jasmine-spec-reporter": "~4.2.1", "karma": "~2.0.5", "karma-chrome-launcher": "~2.2.0", "karma-cli": "~1.0.1", "typescript": "2.7.2", "karma-coverage-istanbul-reporter": "^2.0.1", "karma-jasmine": "~1.1.2", "karma-jasmine-html-reporter": "^1.2.0", "protractor": "~5.4.0", "ts-node": "~7.0.0", "tslint": "~5.11.0" } }
My polyfills.ts:
`/**
*/
/***************************************************************************************************
*/
import 'ie-shim'; // Internet Explorer 9 support.
/** IE9, IE10 and IE11 requires all of the following polyfills. **/
import 'core-js/es6/symbol';
import 'core-js/es6/object';
import 'core-js/es6/function';
import 'core-js/es6/parse-int';
import 'core-js/es6/parse-float';
import 'core-js/es6/number';
import 'core-js/es6/math';
import 'core-js/es6/string';
import 'core-js/es6/date';
import 'core-js/es6/array';
import 'core-js/es6/regexp';
import 'core-js/es6/map';
import 'core-js/es6/weak-map';
import 'core-js/es6/set';
import 'core-js/es6/weak-set';
// import 'core-js/es7/symbol';
// import 'core-js/es7/object';
/** IE10 and IE11 requires the following for NgClass support on SVG elements */
import 'classlist.js'; // Run
npm install --save classlist.js
./** IE10 and IE11 requires the following for the Reflect API. */
import 'core-js/es6/reflect';
/** Evergreen browsers require these. **/
// Used for reflect-metadata in JIT. If you use AOT (and only Angular decorators), you can remove.
import 'core-js/es7/reflect';
/**
@angular/platform-browser/animations
.**/
import 'web-animations-js'; // Run
npm install --save web-animations-js
./***************************************************************************************************
*/
import 'zone.js/dist/zone'; // Included with Angular CLI.
/** Workaround for IE11 and polyfill problem */
import 'isomorphic-fetch';
/***************************************************************************************************
*/
`
And my app.module.ts:
`import { BrowserModule } from '@angular/platform-browser';
import { NgModule, Inject, APP_INITIALIZER, PLATFORM_ID } from '@angular/core';
import { FormsModule } from '@angular/forms';
import { HttpClientModule } from '@angular/common/http';
import { RouterModule } from '@angular/router';
import { isPlatformBrowser } from '@angular/common';
import { AppComponent } from './app.component';
import { NavMenuComponent } from './nav-menu/nav-menu.component';
import { HomeComponent } from './home/home.component';
import {
AuthModule,
OidcSecurityService,
OpenIDImplicitFlowConfiguration,
OidcConfigService,
AuthWellKnownEndpoints
} from 'angular-auth-oidc-client';
import { AutoLoginComponent } from './auto-login/auto-login.component';
import { routing } from './app.routes';
import { ForbiddenComponent } from './forbidden/forbidden.component';
import { UnauthorizedComponent } from './unauthorized/unauthorized.component';
import { ProtectedComponent } from './protected/protected.component';
import { AuthorizationGuard } from './authorization.guard';
import { environment } from '../environments/environment';
export function loadConfig(oidcConfigService: OidcConfigService) {
console.log('APP_INITIALIZER STARTING');
// https://login.microsoftonline.com/damienbod.onmicrosoft.com/.well-known/openid-configuration
// jwt keys: https://login.microsoftonline.com/common/discovery/keys
// Azure AD does not support CORS, so you need to download the OIDC configuration, and use these from the application.
// The jwt keys needs to be configured in the well-known-openid-configuration.json
return () => oidcConfigService.load_using_custom_stsServer('https://my.server.net/adfs/.well-known/openid-configuration');
}
@NgModule({
declarations: [
AppComponent,
NavMenuComponent,
HomeComponent,
AutoLoginComponent,
ForbiddenComponent,
UnauthorizedComponent,
ProtectedComponent
],
imports: [
BrowserModule.withServerTransition({ appId: 'ng-cli-universal' }),
HttpClientModule,
AuthModule.forRoot(),
FormsModule,
routing,
],
providers: [
OidcSecurityService,
OidcConfigService,
{
provide: APP_INITIALIZER,
useFactory: loadConfig,
deps: [OidcConfigService],
multi: true
},
AuthorizationGuard
],
bootstrap: [AppComponent]
})
export class AppModule {
constructor(
@Inject(PLATFORM_ID) private platformId: Object,
private oidcSecurityService: OidcSecurityService,
private oidcConfigService: OidcConfigService,
) {
if (isPlatformBrowser(this.platformId)) {
this.oidcConfigService.onConfigurationLoaded.subscribe(() => {
console.log('Subscribe starting');
console.log(this.oidcConfigService);
console.log(this.oidcConfigService.clientConfiguration);
console.log(this.oidcConfigService.wellKnownEndpoints);
}
}
`
Can you help me, please?
Best regards,
Stefan
The text was updated successfully, but these errors were encountered: