Skip to content

Instantly share code, notes, and snippets.

@pyoner
pyoner / machine.js
Last active October 8, 2020 06:16
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@pyoner
pyoner / machine.js
Last active October 16, 2021 12:34
Generated by XState Viz: https://xstate.js.org/viz
// Project: Gtab
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@pyoner
pyoner / machine.js
Last active October 16, 2021 12:35
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@pyoner
pyoner / machine.js
Last active December 27, 2019 05:28
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@pyoner
pyoner / machine.js
Created December 9, 2019 15:24
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@pyoner
pyoner / machine.js
Last active October 16, 2021 12:30
Generated by XState Viz: https://xstate.js.org/viz
/*
interface Event {
type: string
executor: 'client' | 'provider' | 'admin' | 'validator'
sender: 'admin' | 'client' | 'provider'
}
**/
const guards = {
// executors
@pyoner
pyoner / SketchSystems.spec
Last active December 8, 2019 04:27
Job State Sketch
Job State Sketch
Init
client draft -> Draft
client publish -> AcceptingOffers
Draft
client close -> Closed
client publish -> AcceptingOffers
AcceptingOffers
@pyoner
pyoner / machine.js
Created December 4, 2019 04:20
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@pyoner
pyoner / SketchSystems.spec
Last active December 8, 2019 10:06
Job State Sketch
Job State Sketch
init
client draft -> draft
client publish -> acceptingOffers
# Draft
draft
client publish -> acceptingOffers
client close -> closed
@pyoner
pyoner / SketchSystems.spec
Last active December 18, 2018 14:33
Promise Sketch
Promise Sketch
Pending*
resolve -> Resolved
reject -> Rejected
Resolved
Rejected