New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The view is only updated as per the latest Model when the runtime is passed Cmd.none... #796

Closed
GordonBGood opened this Issue Dec 23, 2016 · 2 comments

Comments

Projects
None yet
3 participants
@GordonBGood

GordonBGood commented Dec 23, 2016

Sometimes one might want intermediate updates, as as the following sequence of tasks:

  1. Respond to a Start Button click by setting state of a running boolean (not doing anyting - exiting sequence - if running is already True).
  2. Take the current time.
  3. Run something
  4. Take the stop time.
  5. Display the results.

Currently, the results and the elapsed time are only displayed at the end (when Cmd.none is sent to the runtime) even though the model is updated at every step, which should cause changes to the view model.

It would be nice if the view model could be updated at intermediate steps, so that one could do such things as disable the Start Button, update status ("Running" instead of "Waiting for Click"), clearing text fields, etc.

This might be easily accomplished by adding a Cmd.update that could be batched with other commands on any given intermediate step of the sequence where the view update should be triggered (or doing special processing for Cmd.none when it is one of the batched Cmd's to treat it like a request for view update - doesn't currently work; it currently only seems to update the view when there is nothing else to do).

@process-bot

This comment has been minimized.

Show comment
Hide comment
@process-bot

process-bot Dec 23, 2016

Thanks for the issue! Make sure it satisfies this checklist. My human colleagues will appreciate it!

Here is what to expect next, and if anyone wants to comment, keep these things in mind.

process-bot commented Dec 23, 2016

Thanks for the issue! Make sure it satisfies this checklist. My human colleagues will appreciate it!

Here is what to expect next, and if anyone wants to comment, keep these things in mind.

@jvoigtlaender

This comment has been minimized.

Show comment
Hide comment
@jvoigtlaender

jvoigtlaender Dec 23, 2016

Contributor

This is something for discussion on the mailing list, instead of the GitHub issue tracker here. (To understand why, have a look at what process-bot points to above.)

Hence, I'm closing this here.

Contributor

jvoigtlaender commented Dec 23, 2016

This is something for discussion on the mailing list, instead of the GitHub issue tracker here. (To understand why, have a look at what process-bot points to above.)

Hence, I'm closing this here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment