Skip to content

Latest commit

 

History

History
20 lines (16 loc) · 482 Bytes

File metadata and controls

20 lines (16 loc) · 482 Bytes

@async Back

The @async tag indicates that a function is asynchronous, which means that the function you called should return a promise.

Note: DO NOT use this tag for other types of asynchronous functions, like functions that provide a callback.

/**
* asynchronous function
* @async
* @returns {Promise<*>}
*/
function asynchronous() {
    return new Promise((resolve, reject) => {});
}

async function main() {
    await asynchronous();
}