Last active
January 4, 2021 23:34
-
-
Save gurdasnijor/3ef1b10ea7a7000e894b68cc97ccfa42 to your computer and use it in GitHub Desktop.
Generated by XState Viz: https://xstate.js.org/viz
This file contains 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
const signupJourney = Machine( | |
{ | |
"key": "cart-abandoned", | |
"initial": "added_sneakers", | |
"states": { | |
"added_sneakers": { | |
"on": { | |
"DIDNT_BUY_SUPREME_ENTERED": "didnt_buy_supreme" | |
}, | |
"meta": { | |
"audience_ast": { | |
"children": [ | |
{ | |
"children": [ | |
{ | |
"children": [ | |
{ | |
"type": "event.property.string", | |
"value": "category" | |
}, | |
{ | |
"type": "constant.string", | |
"value": "Sneakers" | |
} | |
], | |
"type": "operator", | |
"value": "=" | |
} | |
], | |
"type": "event.count", | |
"value": "Product Added" | |
}, | |
{ | |
"type": "constant.integer", | |
"value": "1" | |
} | |
], | |
"type": "operator", | |
"value": ">=" | |
} | |
} | |
}, | |
"didnt_buy_supreme": { | |
"meta": { | |
"audience_ast": { | |
"children": [ | |
{ | |
"children": [ | |
{ | |
"children": [ | |
{ | |
"children": [ | |
{ | |
"children": [ | |
{ | |
"type": "event.property.string", | |
"value": "category" | |
}, | |
{ | |
"type": "constant.string", | |
"value": "Sneakers" | |
} | |
], | |
"type": "operator", | |
"value": "=" | |
}, | |
{ | |
"children": [ | |
{ | |
"type": "event.property.string", | |
"value": "brand" | |
}, | |
{ | |
"type": "constant.string", | |
"value": "Supreme" | |
} | |
], | |
"type": "operator", | |
"value": "=" | |
} | |
], | |
"type": "operator", | |
"value": "and" | |
} | |
], | |
"type": "event.count", | |
"value": "Product Added" | |
}, | |
{ | |
"type": "constant.integer", | |
"value": "1" | |
} | |
], | |
"type": "operator", | |
"value": ">=" | |
}, | |
{ | |
"children": [ | |
{ | |
"type": "event.count", | |
"value": "Checkout Started" | |
}, | |
{ | |
"type": "constant.integer", | |
"value": "0" | |
} | |
], | |
"type": "operator", | |
"value": "=" | |
} | |
], | |
"type": "operator", | |
"value": "and" | |
} | |
} | |
} | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment