JSSynchronizationContext.Post method (1 of 2)
Runs an action on the JS thread, without waiting for completion.
C#
public void Post(Action action, bool allowSync = false)
parameter | description |
---|---|
action | The action to run. |
allowSync | True to allow the action to run immediately if the current synchronization context is this one. By default the action will always be scheduled for later execution. |
See Also
- class JSSynchronizationContext
- namespace Microsoft.JavaScript.NodeApi.Interop
JSSynchronizationContext.Post method (2 of 2)
Runs an asynchronous action on the JS thread, without waiting for completion.
C#
public void Post(Func<Task> asyncAction, bool allowSync = false)
parameter | description |
---|---|
asyncAction | The action to run. |
allowSync | True to allow the action to run immediately if the current synchronization context is this one. By default the action will always be scheduled for later execution. |
See Also
- class JSSynchronizationContext
- namespace Microsoft.JavaScript.NodeApi.Interop