0.0.11 • Published 6 years ago
nz-ng2-interceptors v0.0.11
nz-ng2-interceptors
About
This package contains recommended interceptors to use in your app.
Installation
npm install nz-ng2-interceptors --save
in your module add the interceptors you need
@NgModule({
imports: [
CsrfModule.withOptions(),
TokenAuthenticationModule.withOptions({
tokenStoredIn: TokenStorages.cookies,
tokenKeyName: environment.tokenCookieName
}),
DecorateRequestModule.withOptions({
params: {format: 'json'},
headers: {
'Content-Type': 'application/json'
},
url: environment.serverUrl
}),
]
})
License
MIT