Created
November 20, 2019 22:10
-
-
Save hellobrian/31ea86c99a4e94cc45e7ce739fe8db55 to your computer and use it in GitHub Desktop.
Generated by XState Viz: https://xstate.js.org/viz
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Available variables: | |
// - Machine | |
// - interpret | |
// - assign | |
// - send | |
// - sendParent | |
// - spawn | |
// - raise | |
// - actions | |
// - XState (all XState exports) | |
const clientEngagmentMachine = Machine({ | |
id: 'clientEngagmentMachine', | |
initial: 'submitted_to_client', | |
states: { | |
submitted_to_client: { | |
on: { | |
YES: 'interview_scheduling_started', | |
MAYBE: 'client_requested_additional_info', | |
NO: 'client_rejected_candidate' | |
} | |
}, | |
interview_scheduling_started: { | |
on: { | |
SCHEDULED: 'interview_scheduling_done' | |
} | |
}, | |
interview_scheduling_done: { | |
on: { | |
ADDITIONAL_INTERVIEW: 'interview_scheduling_started', | |
YES: 'offer_extended', | |
NO: 'client_rejected_candidate' | |
} | |
}, | |
client_requested_additional_info: { | |
on: { | |
NO: 'client_rejected_candidate', | |
MAYBE: 'client_requested_additional_info' | |
} | |
}, | |
client_rejected_candidate: { | |
type: 'final' | |
}, | |
offer_extended: { | |
type: 'final' | |
} | |
} | |
}); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment