The StateHasChanged
method is called whenever a bound property is changed or a UI event triggered
for an instance. This notifies the Blazor that the component should rerender
it.
For example, when a button is clicked in the index page, the index component rerenders
(no need to call StateHasChanged) because the button’s parent is an
index; but when it has a child component it has be notified to render as the
parent has changed.
Share with