async function testAsync() {
return Promise.resolve("hello async");
}
function takeLongTime() {
return new Promise(resolve => {
setTimeout(() => resolve("long_time_value"), 1000);
});
}
async function testAsync() {
return Promise.resolve("hello async");
}
function takeLongTime() {
return new Promise(resolve => {
setTimeout(() => resolve("long_time_value"), 1000);
});
}