Closed edoardocavazza closed 5 years ago
When using this plugin with inlineHelpers: true, async methods should always return a Promise also if not using the await keyword.
inlineHelpers: true
await
Example:
class MyClass { static async check() { return true; } }; console.log(MyClass.check() instanceof Promise); // -> true
is transpiled to:
class MyClass { static check() { try { return true; } catch (e) { return Promise.reject(e); } } } console.log(MyClass.check() instanceof Promise); // -> false
When using this plugin with
inlineHelpers: true
, async methods should always return a Promise also if not using theawait
keyword.Example:
is transpiled to: