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
| const auth = Machine({ | |
| id: 'auth', | |
| initial: 'idle', | |
| context: { | |
| strategy: 'phone', | |
| availableStrategies: ['phone', 'email'] | |
| }, | |
| states: { | |
| idle: { |
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
| const m = Machine({ | |
| initial: "initializing", | |
| states: { | |
| initializing: { | |
| invoke: { | |
| src: "fetch", | |
| onDone: "ready", | |
| }, | |
| }, | |
| ready: { |
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 |
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
| const m = Machine({ | |
| initial: 'initializing', | |
| context: { | |
| processing: false | |
| }, | |
| states: { | |
| initializing: { | |
| invoke: { | |
| src: 'fetchAccounts', |
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 |
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
| const m = Machine({ | |
| initial: "initializing", | |
| context: { | |
| processing: false, | |
| }, | |
| states: { | |
| initializing: { | |
| invoke: { | |
| src: "fetchAccounts", | |
| onDone: { target: "ready" }, |
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
| Machine({ | |
| strict: true, | |
| id: "suflerMachine", | |
| context: { | |
| config: { | |
| shouldLoadUserTransactions: false, | |
| market: "B2C" | |
| }, | |
| user: { | |
| isLoggedIn: true, |
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
| const stepTransitions = Machine({ | |
| initial: "idle", | |
| states: { | |
| idle: { | |
| id: "idle", | |
| on: { | |
| START: { target: "inProgress" }, | |
| }, | |
| }, | |
| inProgress: { |
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
| const m = Machine({ | |
| "id": "root", | |
| "states": { | |
| "Otworzenie portalu": { | |
| "id": "Otworzenie portalu", | |
| "states": { | |
| "Jest to strona SG B2C lub B2B?": { | |
| "id": "Jest to strona SG B2C lub B2B?", | |
| "states": {}, | |
| "on": { |
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
| Otworzenie portalu* | |
| Jest to strona SG B2C lub B2B? | |
| Tak -> Sprawdzenie ciastka | |
| Nie -> Koniec | |
| Sprawdzenie ciastka | |
| Uzytkownik jest w wersji A -> Wyślij B2B_rozbiegowka_test_A | |
| Użytkownik jest w wersji B -> Eventy dla wersji B | |