Skip to content

Instantly share code, notes, and snippets.

View scarabaeus's full-sized avatar
🍹

Steve G. scarabaeus

🍹
  • San Francisco, CA
  • 06:01 (UTC -07:00)
View GitHub Profile
@scarabaeus
scarabaeus / machine.js
Last active September 16, 2021 15:49
Generated by XState Viz: https://xstate.js.org/viz
// https://xstate.js.org/viz/?gist=f48e92c2eca22f9af7eeb1b9ce8cebfa
const fetchMachine = Machine({
id: 'toggle',
initial: 'paymentAgreement',
context: {
paymentMethod: '',
debitMaximum: 50000,
checkMinimum: 100,
@scarabaeus
scarabaeus / machine.js
Last active January 22, 2021 23:29
Generated by XState Viz: https://xstate.js.org/viz
const fetchMachine = Machine({
id: 'fetch',
initial: 'WELCOME SCREEN',
context: {},
states: {
'WELCOME SCREEN': {
on: {
'STEP 1': 'STEP ONE SCREEN'
}
},
const fetchMachine = Machine({
id: 'Mock One',
initial: 'entryPoint',
context: {
retries: 0
},
states: {
'entryPoint': {
on: {
const postMessage = (messageName) => ([messageName]);
const fetchMachine = Machine({
id: 'Single Party Pole Hit',
initial: 'Claim Created',
context: {
retries: 0
},
states: {
const showNotifications = false;
const showExceptions = false;
const showSkipEvents = false;
const forwardOnlySkips = true;
const notificationActions = (stepName) => showNotifications ? ([`Send ${stepName} SMS`, `Send ${stepName} Email`, `Send ${stepName} Via Other`]) : ([]);
const claimDispositionActions = notificationActions('Claim Disposition');

Keybase proof

I hereby claim:

  • I am scarabaeus on github.
  • I am steve_gomez (https://keybase.io/steve_gomez) on keybase.
  • I have a public key ASB2uWkCGpRXTzju2IXs0BfaLbCV_7afbyI_d8uT3130Ego

To claim this, I am signing this object:

const assetDetailPage = {}
const fetchMachine = Machine({
id: '/assets/:id',
initial: 'loadingAsset',
context: {
pageTitle: '',
loadingAsset: true,
name: '',
locale: '',
@scarabaeus
scarabaeus / Create iOS Icons.jsx
Last active February 9, 2016 15:04 — forked from RichardBronosky/Create iOS Icons.jsx
A modification of the "Create iOS Icons.jsx" script to output file names matching [NativeScript](http://www.nativescript.org) expected convention for iOS.
// Photoshop Script to Create iPhone Icons image (Specifically matching NativeScript icon names.)
// Original: https://gist.github.com/appsbynight/3681050
// Turn debugger on. 0 is off.
// $.level = 1;
try
{
// Prompt user to select iTunesArtwork file. Clicking "Cancel" returns null.
var iTunesArtwork = File.openDialog("Select a sqaure PNG file that is at least 1024x1024.", "*.png", false);