Running following code causes apply(...) is not a function
and I'm not sure why.
I feel like invoking apply for async functions not possible. What's correct way then to get apply like calling behavior?
async function throwSomething() {
return "Apple";
}
async function caughtSomething() {
try {
return await throwSomething.apply(this, arguments || [])();
} catch(e) {
console.log(e);
}
}
caughtSomething();