Skip to content

Instantly share code, notes, and snippets.

@edorivai
Last active February 23, 2021 12:20
Show Gist options
  • Save edorivai/9539d780f3cf95c1eb0f4ccac96ff65c to your computer and use it in GitHub Desktop.
Save edorivai/9539d780f3cf95c1eb0f4ccac96ff65c to your computer and use it in GitHub Desktop.
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
// - XState (all XState exports)
const hubspotMachine = Machine({
id: 'hubspot',
initial: 'invited_not_logged_in',
context: {
},
states: {
invited_not_logged_in: {
on: {
LOGIN: 'active_first_15_days',
DELETE: 'removed_from_dashboard'
}
},
active_first_15_days: {
on: {
PASSED_15_DAY_MARK: 'active_users_after_15_days',
DELETE: 'removed_from_dashboard'
}
},
active_users_after_15_days: {
on: {
DELETE: 'removed_from_dashboard'
}
},
removed_from_dashboard: {
on: {
ADD: 'invited_not_logged_in'
}
}
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment