Re: [w3c/manifest] Add installation prompt control flow (#417)

I see, so you're saying that you can call `prompt` many times and it will just return a bunch of promises, all of which get resolved at the same time?

> The drawback of the above is that we need to keep a queue of promises that are waiting an outcome.

Can't we just have prompt() always return the same promise? In effect, it just returns the userChoice promise that we used to have as an attribute. Then surely we don't need a queue.

I think the reason for that error is that if you call `prompt()` *after* the dialog choice is made, it should not be a no-op. It should "try" to prompt again and fail because you're only allowed to do that once.

So I'd be happy for:

1. `prompt()`
2. `prompt()`
3. Click Install.

To have both promises succeed, but

1. `prompt()`
2. Click Install.
3. `prompt()`

to have the second prompt fail. Does that sound OK?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/manifest/issues/417#issuecomment-257790134

Received on Wednesday, 2 November 2016 07:19:33 UTC