From f45e9e070c93ebbd83d488bdd775987a4d75c201 Mon Sep 17 00:00:00 2001 From: t7yang Date: Mon, 10 Jan 2022 08:38:08 +0800 Subject: fix yari h2m dry run errors --- .../web/javascript/reference/global_objects/asyncfunction/index.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'files/zh-tw/web/javascript/reference/global_objects/asyncfunction') diff --git a/files/zh-tw/web/javascript/reference/global_objects/asyncfunction/index.html b/files/zh-tw/web/javascript/reference/global_objects/asyncfunction/index.html index c25f3ee3a1..8890a3bc65 100644 --- a/files/zh-tw/web/javascript/reference/global_objects/asyncfunction/index.html +++ b/files/zh-tw/web/javascript/reference/global_objects/asyncfunction/index.html @@ -31,7 +31,7 @@ translation_of: Web/JavaScript/Reference/Global_Objects/AsyncFunction

All arguments passed to the function are treated as the names of the identifiers of the parameters in the function to be created, in the order in which they are passed.

-
+

Note: {{jsxref("Statements/async_function", "async functions")}} created with the AsyncFunction constructor do not create closures to their creation contexts; they are always created in the global scope. When running them, they will only be able to access their own local variables and global ones, not the ones from the scope in which the AsyncFunction constructor was called. This is different from using {{jsxref("Global_Objects/eval", "eval")}} with code for an async function expression.

-- cgit v1.2.3-54-g00ecf