mirror of
https://github.com/esiur/esiur-js.git
synced 2025-06-27 15:23:11 +00:00
AsyncReply is Promise
This commit is contained in:
12
test/test.js
12
test/test.js
@ -8,6 +8,15 @@ class MyStore extends IStore
|
||||
|
||||
}
|
||||
|
||||
async function load()
|
||||
{
|
||||
window.x = await wh.get("iip://localhost:5001/db/my", {username: "demo", password: "1234"});
|
||||
console.log(window.x);
|
||||
}
|
||||
|
||||
load();
|
||||
|
||||
/*
|
||||
wh.get("iip://localhost:5001/db/my", {username: "demo", password: "1234"})
|
||||
.then(x=>{
|
||||
console.log("connected", x);
|
||||
@ -15,4 +24,5 @@ wh.get("iip://localhost:5001/db/my", {username: "demo", password: "1234"})
|
||||
window.x = x;
|
||||
}).catch(x=>{
|
||||
console.log("error", x);
|
||||
});
|
||||
});
|
||||
*/
|
Reference in New Issue
Block a user