twilio-ivr
twilio-ivr copied to clipboard
allow non-renderable async states
I'm not sure what the harm is...
[this would require updating resolveBranches to call backgroundTrigger as we branch over these non-renderable states, and it would require listing AsyncState explicitly in the UsableState type if it's not already].
It would also mean that an async state needs to be branching or renderable. Because if it's not either (i.e., if it just has backgroundTrigger()), then there's no twiml to respond to the user with when we branch to it.
So being async would become like being routable: it can be applied to either a branching state or a renderable state, but a state that's just async is invalid.
Under the proposal in #7, something like this could become beforeTransitionOut...