Skip to content

[browser] JSMarshalAs(JSType.Function) support for Task #101913

Open
@kekekeks

Description

@kekekeks

We actively utilize JSType.Function for JS->managed callbacks and encountering problems when trying to add support for multithreaded mode: MT requires JS->managed calls to be async, however returning Task type doesn't work for JSType.Function:

Error SYSLIB1072 : The type 'System.Func<System.Threading.Tasks.Task>' is not supported by source-generated JavaScript interop.
The generated source will not handle marshalling of parameter 'callback'.
For more information see https://aka.ms/dotnet-wasm-jsinterop

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions