V8SettingsEnableTopLevelAwait Property |
Note: This API is now obsolete.
Enables or disables Top-Level Await.
Namespace: Microsoft.ClearScript.V8Assembly: ClearScript.V8 (in ClearScript.V8.dll) Version: 7.4.5
Syntax [ObsoleteAttribute("V8 no longer supports Top-Level Await control. The feature is always enabled.")]
public static bool EnableTopLevelAwait { get; set; }
<ObsoleteAttribute("V8 no longer supports Top-Level Await control. The feature is always enabled.")>
Public Shared Property EnableTopLevelAwait As Boolean
Get
Set
public:
[ObsoleteAttribute(L"V8 no longer supports Top-Level Await control. The feature is always enabled.")]
static property bool EnableTopLevelAwait {
bool get ();
void set (bool value);
}
[<ObsoleteAttribute("V8 no longer supports Top-Level Await control. The feature is always enabled.")>]
static member EnableTopLevelAwait : bool with get, set
Property Value
BooleanRemarks Top-Level Await
enables code at the outermost scope of an
ECMAScript 6
module to be executed as an
async function.
When this feature is enabled, modules can await resources, causing importers to
delay evaluation as necessary.
To enable Top-Level Await, set this property to true before instantiating
V8ScriptEngine or V8Runtime for the first time. Subsequent
reassignment will have no effect.
See Also