Skip to content

Instantly share code, notes, and snippets.


Jeremy Mack mutewinter

View GitHub Profile
mutewinter / imageSizes.ts
Last active Dec 2, 2021
Utility to help generate image sizes for the Next Image component when using Tailwind via Twin.macro
View imageSizes.ts
import { theme } from 'twin.macro';
function minMediaCondition(minWidth: string, width: string) {
return `(min-width: ${minWidth}) ${width}`;
type Screens = 'sm' | 'md' | 'lg';
// We only do sizes in terms of view width
type SizeWithScreen<T extends Screens> = [screen: T, width: `${string}vw`];
mutewinter / focusAlert.lua
Created Apr 9, 2018
Hammerspoon App Focus Alert
View focusAlert.lua
-- --------------------------
-- Alert When App Not Focused
-- --------------------------
local alertInSeconds = 60 * 20
local alertAppName = 'App You Want to Focus Here'
local alertTimer
local function stopTimerAlertTimer()
mutewinter /
Last active Dec 8, 2021
Prevent Double Tap Zoom in React for Rapidly Tapped Buttons

Prevent Double Tap Zoom in React for Rapidly Tapped Buttons

Touch delay is [a thing of the past][td], but accidental zooming is here to ruin your day. Ever tapped a button quickly on iOS and experienced a zoom instead of two taps? You're in the right place.



mutewinter / package.json
Created Oct 4, 2016
Use Jest with CoffeeScript
View package.json
"jest": {
"moduleFileExtensions": [
"preprocessorIgnorePatterns": [ ],
mutewinter /
Last active Feb 8, 2018
Magic Import for Vim UltiSnips

Magic Import for Vim UltiSnips

GIF of magic import in action

  1. Be a Vim user.
  2. Install UltiSnips.
  3. Add the code below to $YOUR_VIM_FOLDER/UltiSnips/javascript.snippets.
snippet ii "magic import" b
import `!p
mutewinter /
Last active May 18, 2020
T-Shirt sizes we use for estimation at Postlight


Size What it means
▁ S 💅 I can get this done in one session at the computer with no breaks
▃ M This will require breaks, less than a day
▅ L 💦 This will require more than one day
▇ XL 😱 Rare! This will require a week or more. Try breaking into multiple smaller issues
mutewinter / devServer.js
Last active Jun 13, 2016
Minimal output from Webpack
View devServer.js
var webpack = require('webpack');
var WebpackDevServer = require('webpack-dev-server');
var config = require('./webpack.config');
var PORT = process.env.PORT || 1337;
new WebpackDevServer(webpack(config), {
publicPath: config.output.publicPath,
hot: true,
quiet: false,
mutewinter /
Last active Dec 9, 2015
Trello Userstyle to Show Label Names and Order Black Labels First
mutewinter / userstyle.css
Last active Sep 22, 2016
My Flowdock UserStyle. Goes in ~/Library/Application Support/Flowdock/userstyle.css
View userstyle.css
.emojie {
line-height: 1rem !important;
.bubble.thread {
opacity: 0.65;
} {
border-color: #9554D2 !important;