https://github.com/liuy97/http-ie-helper
https://github.com/liuy97/http-ie-helper
angular httpclient ie ie11
Last synced: 7 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/liuy97/http-ie-helper
- Owner: liuy97
- License: mit
- Created: 2018-06-06T08:41:30.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-10-18T19:06:11.000Z (almost 7 years ago)
- Last Synced: 2025-02-16T20:47:52.095Z (8 months ago)
- Topics: angular, httpclient, ie, ie11
- Language: TypeScript
- Size: 196 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# http-ie-helper - Get request will be sent with no-cache in IE 11.
[](https://badge.fury.io/js/http-ie-helper),
[](https://travis-ci.org/liuy97/http-ie-helper)
[](https://coveralls.io/github/liuy97/http-ie-helper?branch=master)
[](https://david-dm.org/liuy97/http-ie-helper)
[](https://david-dm.org/liuy97/http-ie-helper#info=devDependencies)## Demo
View all the directives in action at https://liuy97.github.io/http-ie-helper
## Dependencies
* [Angular](https://angular.io) (*requires* Angular 4.3 or higher, tested with 4.3.0)## Installation
Install above dependencies via *npm*.Now install `http-ie-helper` via:
```shell
npm install --save http-ie-helper
```---
##### SystemJS
>**Note**:If you are using `SystemJS`, you should adjust your configuration to point to the UMD bundle.
In your systemjs config file, `map` needs to tell the System loader where to look for `http-ie-helper`:
```js
map: {
'http-ie-helper': 'node_modules/http-ie-helper/bundles/http-ie-helper.umd.js',
}
```
---Once installed you need to import the main module:
```js
import { HttpIEHelperModule } from 'http-ie-helper';
```
The only remaining part is to list the imported module in your application module. The exact method will be slightly
different for the root (top-level) module for which you should end up with the code similar to (notice ` HttpIEHelperModule .forRoot()`):
```js
import { HttpIEHelperModule, HttpIEHelperInterceptor } from 'http-ie-helper';@NgModule({
declarations: [AppComponent, ...],
imports: [HttpIEHelperModule.forRoot(), ...],
providers: [{ provide: HTTP_INTERCEPTORS, useClass: HttpIEHelperInterceptor, multi: true }],
bootstrap: [AppComponent]
})
export class AppModule {
}
```Other modules in your application can simply import ` HttpIEHelperModule ` and provide HttpIEHelperInterceptor:
```js
import { HttpIEHelperModule, HttpIEHelperInterceptor } from 'http-ie-helper';@NgModule({
declarations: [OtherComponent, ...],
imports: [HttpIEHelperModule, ...],
providers: [{ provide: HTTP_INTERCEPTORS, useClass: HttpIEHelperInterceptor, multi: true }],
})
export class OtherModule {
}
```## Usage
## License
Copyright (c) 2018 Yong Liu. Licensed under the MIT License (MIT)