Files
Angular-Docs-Cn/modules/@angular/http/src/backends/browser_xhr.ts
T

13 lines
295 B
TypeScript
Raw Normal View History

import {Injectable} from '@angular/core';
2015-04-28 23:07:55 -07:00
/**
* A backend for http that uses the `XMLHttpRequest` browser API.
*
* Take care not to evaluate this in non-browser contexts.
*/
2015-04-28 23:07:55 -07:00
@Injectable()
export class BrowserXhr {
constructor() {}
build(): any { return <any>(new XMLHttpRequest()); }
2015-04-28 23:07:55 -07:00
}