Skip to main content
Version: 2.x

API Reference > @next-core/brick-kit > PropertyDeclaration > hasChanged

PropertyDeclaration.hasChanged() method

A function that indicates if a property should be considered changed when it is set. The function should take the newValue and oldValue and return true if an update should be requested.

Signature:

hasChanged?(value: Type, oldValue: Type): boolean;

Parameters

ParameterTypeDescription
valueType
oldValueType

Returns:

boolean