Writing

Thoughts about coding.

All Posts

  1. Ignoring files you've already committed

    Cache invalidation is tricky to automate.

    Updated 3 months ago

  2. Converting a list of JS objects into a parent-child tree

    A fun nesting puzzle.

    Updated 1 year ago

  3. A "!" prefix makes any Tailwind CSS class important

    A delightfully succinct bit of syntax.

    Updated 1 year ago

  4. Tmux's version command is -V

    Probably the last option you’d think to try.

    Updated 1 year ago

  5. SELECT DISTINCT outputs a column's unique values

    A very useful keyword when you’re trying to understand sets of values.

    Updated 1 year ago

  6. It's tricky to statically type a "pipe" function in Python

    Less tricky once you understand overloads better.

    Updated 1 year ago

  7. An iOS Shortcut can add data to a Google Sheet

    Workflows you can complete from your phone are seriously underrated.

    Updated 1 year ago

  8. How to query a BigQuery table from Python

    Doesn’t take much to pull in a whole lotta data.

    Updated 1 year ago

  9. CloudFlare sells domain names at cost

    Consumer pricing doesn’t often go down.

    Updated 1 year ago

  10. Homebrew packages might install dependencies

    Brew packages install brew packages.

    Updated 1 year ago

  11. Shell functions don’t need parentheses

    Just in case you see this in the wild and are confused.

    Updated 1 year ago

  12. You can run shell scripts in tmux.conf

    It’s a nice way to integrate whatever behaviour you like.

    Updated 1 year ago

  13. Why unknown types are useful

    Sometimes you want the type checker to help you avoid making assumptions.

    Updated 1 year ago

  14. Using "object" as an unknown type in Python

    Python's base class (and base type) can help keep you safe when your data could be anything.

    Updated 1 year ago

  15. Defining a custom unknown type in Python

    How to replicate TypeScript's unknown type with a generic type variable.

    Updated 1 year ago

  16. Undoing a merge to your main git branch

    How to roll back changes by reverting commits

    Updated 2 years ago

  17. Switching configs in Neovim

    How to maintain multiple Neovim configurations and switch between them

    Updated 2 years ago

  18. Adding a pull request template to your GitHub repo

    How to pre-fill the blank description with helpful prompts.

    Updated 3 years ago

  19. Dramatically reducing video file size using FFmpeg

    How to shrink a video so it’s small enough to upload.

    Updated 3 years ago

  20. The translateZ trick

    How to smoothly animate CSS filters in Safari by engaging the GPU.

    Updated 3 years ago

  21. What is a Factory Function?

    Kyle Shevlin on how to use factory functions as an alternative to classes.

    Updated 3 years ago

  22. Writing Great Alt Text

    Jake Archibald on how to write better image alt text.

    Updated 3 years ago

  23. Levels of Abstraction in Testing

    Sam Selikoff on how to make unit tests easier to read.

    Updated 3 years ago

  24. Using Slack to report data entry errors to content editors

    How the ".com" team at ecobee uses Slack as an alert system.

    Updated 4 years ago

  25. The

    How to remove empty values from an array.

    Updated 5 years ago

  26. Using GraphQL with Gatsby

    How to write GraphQL queries in a Gatsby project.

    Updated 6 years ago

  27. Adding content to a Gatsby project

    The pros and cons of different approaches.

    Updated 6 years ago

  28. Writing CSS-in-JS in a Gatsby project

    How CSS-in-JS libraries like CSS Modules and Styled Components make it easier to safely add and remove styles.

    Updated 6 years ago

  29. Writing CSS in a Gatsby project

    How to write traditional CSS in a Gatsby project.

    Updated 6 years ago

  30. Wrapping pages in a layout component

    How to share common content and styling between pages.

    Updated 6 years ago

  31. Adding pages to a Gatsby project

    How to add pages to a Gatsby project and navigate between them.

    Updated 6 years ago

  32. Writing HTML in a Gatsby project

    How to use React to split HTML into reusable components.

    Updated 6 years ago

  33. Gatsby's default files and folders

    What's going on inside each folder in a Gatsby project.

    Updated 6 years ago

  34. Starting a new Gatsby project

    How to start a Gatsby project on your computer.

    Updated 6 years ago

  35. What is Gatsby?

    How Gatsby combines the best features of React and HTML.

    Updated 6 years ago

  36. Introducing Gatsby Tutorials

    A new, community-updated directory of Gatsby.js learning resources.

    Updated 7 years ago

  37. How to set up a Mac for web development

    What to install on your Mac before starting a JavaScript project.

    Updated 7 years ago