Re: Refresh action

>
> I understand the need for rebuild and recalculate, less the need for
> revalidate, but I can't imagine any use case for refresh.


Refresh as a side-effect dispatches UI events (`xforms-value-changed`,
etc.). So if you are running an action and want *everything* in your form
to be up to date in the middle of an action, then `refresh` allows you to
do that. Note that other actions, such as `toggle` and `setindex` in effect
force a refresh as part of their execution.

In addition, any function which requires asking controls themselves for
information, such as `index()`, `case()`, will be up to date only after a
refresh.

I have used `refresh` on occasion.

-Erik

Received on Tuesday, 11 April 2017 17:54:51 UTC