Skip to content

Instantly share code, notes, and snippets.

View derek-duncan's full-sized avatar

Derek Duncan derek-duncan

View GitHub Profile
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@derek-duncan
derek-duncan / SketchSystems.spec
Created November 20, 2019 17:50
Instinct Happy Paths
Instinct Happy Paths
Lockscreen*
Practice Login*
login practice -> User Login
User Login
login user -> Status Board
Status Board&
@derek-duncan
derek-duncan / SketchSystems.spec
Last active November 15, 2019 16:53
Internal Admin Tools
Internal Admin Tools
Logged Out*
log in -> Bulk Admin
Bulk Admin
practice selected -> Show Preview?
action selected -> Preview
csv selected -> CSV Upload
# Clears the form
@derek-duncan
derek-duncan / machine.js
Created September 16, 2019 19:07
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@derek-duncan
derek-duncan / machine.js
Created August 27, 2019 19:17
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@derek-duncan
derek-duncan / machine.js
Created August 23, 2019 20:51
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@derek-duncan
derek-duncan / machine.js
Last active August 21, 2019 20:14
Generated by XState Viz: https://xstate.js.org/viz
Machine({
context: {
entryType: null,
isPending: false,
isDropping: false,
dropStatus: 'idle',
formError: null,
locationId: null,
practiceId: null,
practices: [],
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@derek-duncan
derek-duncan / react@16.7.0-alpha.0-typescript-types-hooks.d.ts
Last active January 26, 2019 18:56
React 16.7.0-alpha.0 Typescript Types for Hooks
// put me in your global.d.ts file
declare module 'react' {
/**
* Returns a stateful value, and a function to update it.
*/
function useState<TValue>(
initialState: TValue | (() => TValue)
): [TValue, (value: TValue | ((prevValue: TValue) => TValue)) => void];
Writeback
Idle*
START_WRITEBACK -> Verify
Verify
VerifyPending
VERIFY_FAIL -> VerifyError
VERIFY_SUCCEED -> Send
VerifyError
VERIFY -> VerifyPending
VERIFY_CANCEL -> Idle