Logo
Explore Help
Sign In
iSharkFly-Docs/angular-docs-cn
1
0
Fork 0
You've already forked angular-docs-cn
Code Issues Pull Requests Actions Packages Projects Releases Wiki Activity
angular-docs-cn/modules/angular2/src/http/backends/browser_xhr.ts

11 lines
249 B
TypeScript
Raw Normal View History

feat(http): add basic http service This implementation only works in JavaScript, while the Observable transpilation story gets worked out. Right now, the service just makes a simple request, and returns an Observable of Response. Additional functionality will be captured in separate issues. Fixes #2028
2015-04-28 23:07:55 -07:00
declare var window;
import {Injectable} from 'angular2/di';
// Make sure not to evaluate this in a non-browser environment!
@Injectable()
export class BrowserXHR {
feat(http): refactor library to work in dart Mostly internal refactoring needed to make ts2dart and DartAnalyzer happy. Fixes #2415
2015-06-19 12:14:12 -07:00
constructor() {}
build(): any { return <any>(new window.XMLHttpRequest()); }
feat(http): add basic http service This implementation only works in JavaScript, while the Observable transpilation story gets worked out. Right now, the service just makes a simple request, and returns an Observable of Response. Additional functionality will be captured in separate issues. Fixes #2028
2015-04-28 23:07:55 -07:00
}
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.23.8 Page: 72ms Template: 3ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API