onPropsChanged( )


Adds an event handler that runs when the value of a widget property is changed.

A widget receives an onPropsChanged event when one or more of its properties is changed via its API.

Method Declaration
Copy
Method Parameters
handlerfunctionRequired

handler(oldProps: object, newProps: object): void The name of the function or the function expression to run when the value of a widget property is changed.

Returns
Return Type:any
Errors

This method doesn’t return any custom errors, but may return standard errors. Learn more about standard Wix errors.

Did this help?