Added functioning search

This commit is contained in:
2017-06-20 22:54:45 +02:00
parent 1598ebd93b
commit 65d43d2b43
13 changed files with 198 additions and 50 deletions

View File

@ -32,6 +32,11 @@ export class Application {
}
get(url: string): Promise<string> {
if(this.lastRequest) {
this.lastRequest.abort()
this.lastRequest = null
}
return new Promise((resolve, reject) => {
let request = new XMLHttpRequest()
@ -52,11 +57,6 @@ export class Application {
}
load(url: string, options?: LoadOptions) {
if(this.lastRequest) {
this.lastRequest.abort()
this.lastRequest = null
}
if(!options) {
options = new LoadOptions()
}