Skip to content

Instantly share code, notes, and snippets.

@pankajparkar
Created March 8, 2020 17:05
Show Gist options
  • Save pankajparkar/9ea37c0a1a49c51bca6987c63794d0fb to your computer and use it in GitHub Desktop.
Save pankajparkar/9ea37c0a1a49c51bca6987c63794d0fb to your computer and use it in GitHub Desktop.
import { HTTP_INTERCEPTORS } from '@angular/common/http';
import { TokenInterceptor } from './../auth/token.interceptor';
@NgModule({
bootstrap: [AppComponent],
imports: [...],
providers: [
{
provide: HTTP_INTERCEPTORS,
useClass: TokenInterceptorService,
multi: true
}
]
})
export class AppModule {}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment