@microsoft/fast-element > ExpressionNotifier > setMode

ExpressionNotifier.setMode() method

Sets the update mode used by the observer.

Signature:

setMode(isAsync: boolean): void;

Parameters

Parameter

Type

Description

isAsync

boolean

Indicates whether updates should be asynchronous.

Returns:

void

Remarks

By default, the update mode is asynchronous, since that provides the best performance for template rendering scenarios. Passing false to setMode will instead cause the observer to notify subscribers immediately when changes occur.