Skip to content

Instantly share code, notes, and snippets.

@imrvelj
Created May 30, 2017 15:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save imrvelj/51f16df0d6a66153f36fa94d0039f033 to your computer and use it in GitHub Desktop.
Save imrvelj/51f16df0d6a66153f36fa94d0039f033 to your computer and use it in GitHub Desktop.
When returned from a TransitionHookFn or TransitionStateHookFn, these values alter the running Transition:
False: the transition will be cancelled.
TargetState: the transition will be redirected to the new target state.
Promise: the transition will wait for the promise to resolve or reject. (see below)
If the promise is rejected (or resolves to false), the transition will be cancelled
If the promise resolves to a TargetState, the transition will be redirected
If the promise resolves to anything else, the transition will resume
Anything else: the transition will resume
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment