@microsoft/fast-element > UpdateQueue > setMode
UpdateQueue.setMode() method
Sets the update mode used by enqueue.
Signature:
setMode(isAsync: boolean): void;
Parameters
|
Parameter |
Type |
Description |
|---|---|---|
|
isAsync |
boolean |
Indicates whether DOM updates should be asynchronous. |
Returns:
void
Remarks
By default, the update mode is asynchronous, since that provides the best performance in the browser. Passing false to setMode will instead cause the queue to be immediately processed for each call to enqueue. However, ordering will still be preserved so that nested tasks do not run until after parent tasks complete.