Skip to content

Instantly share code, notes, and snippets.

View jesstelford's full-sized avatar

Jess Telford jesstelford

View GitHub Profile
@jesstelford
jesstelford / machine.js
Created September 21, 2020 01:44
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
// - XState (all XState exports)
@jesstelford
jesstelford / machine.js
Created September 21, 2020 01:36
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
// - XState (all XState exports)
@jesstelford
jesstelford / README.md
Last active July 9, 2020 12:42
A fork of Capsize used to generate a typographic scale (https://github.com/seek-oss/capsize)

A fork of Capsize used to generate a typographic scale (https://github.com/seek-oss/capsize)

Generate the typographic scale by running generate-typographic-scale.js:

node generate-typographic-scale.js

Add it to your Chakra UI theme under the key typography:

@jesstelford
jesstelford / detect-dangling-relationships.js
Last active April 14, 2020 13:59
Detect relationship inconsistencies in Keystone databases prior to the [Arcade](https://www.keystonejs.com/discussions/new-data-schema) release
/**
* NOTE: We use console.error for log output below so that the output can be
* redirected to a file by the user
*/
const path = require('path');
const entryFile = process.argv[2];
if (!entryFile) {
@jesstelford
jesstelford / machine.js
Last active March 26, 2020 13:42
Generated by XState Viz: https://xstate.js.org/viz
// Available variables:
// - Machine
// - interpret
// - assign
// - send
// - sendParent
// - spawn
// - raise
// - actions
@jesstelford
jesstelford / machine.js
Last active August 27, 2019 05:26
Generated by XState Viz: https://xstate.js.org/viz
// Vocal 'publishStatus' state machine
const machineId = 'publishing';
const publishMachine = Machine(
{
id: machineId,
initial: 'draft',
states: {
uninitialized: {
on: {
draft: 'draft',
@jesstelford
jesstelford / machine.js
Last active August 27, 2019 05:27
Generated by XState Viz: https://xstate.js.org/viz
// Partial representation of old `publishStatus` & `reviewStatus` states in Legacy Vocal.
// See https://xstate.js.org/viz/?gist=6a25309b09bd2a70a9a678ca9ee7fa2b for the latest Replatform version.
const machineId = 'publishing';
const publishMachine = Machine({
id: machineId,
initial: 'draft',
states: {
draft: {
on: {
SUBMIT: 'submitted',
@jesstelford
jesstelford / machine.js
Last active August 27, 2019 05:26
Generated by XState Viz: https://xstate.js.org/viz
// Vocal 'publishStatus' state machine
const machineId = 'publishing';
const publishMachine = Machine(
{
id: machineId,
initial: 'draft',
states: {
uninitialized: {
on: {
draft: 'draft',
@jesstelford
jesstelford / 01-shape-up-to-kindle.md
Last active January 10, 2024 20:08
Read SHAPE UP by basecamp on a Kindle / reMarkable / eReader

Read Shape Up by basecamp on a kindle / reMarkable / eReader

Basecamp's new book Shape Up is now available online (https://basecamp.com/shapeup) to read page-by-page.

There is a .pdf version, but that's not the best format for Kindle / other eReaders. Instead, we can convert the page-by-page into an eReader friendly format.

Part 1: Convert to a single page

NOTE: This has only been tested on Chrome

Getting started

  • Everything except images in a website is text, so it's a lot of reading and writing. As such, it makes sense to use an editor built for the purpose to make your life easier.
  • Install Visual Studio Code (VSCode): https://code.visualstudio.com/
  • There are 3 main technologies that make up a website: HTML, CSS, JavaScript (JS)