Skip to content

Instantly share code, notes, and snippets.

View nummi's full-sized avatar
😺
Working from home

Jerry Nummi nummi

😺
Working from home
View GitHub Profile
@mixonic
mixonic / readme.md
Last active August 15, 2024 15:15
Services for Glimmer.js

Setup

In config/environment.js:

// config/environment.js
'use strict';

/*
 * Mostly this is the stock module config.
@searls
searls / preview.sh
Created June 15, 2019 21:34
A script I wrote to preview a build directory (in my case Hugo's `public` folder, but adjust to taste).
#!/bin/sh
port=${1-1919}
# 1. Navigate to the built folder & start a server in it
cd public
python -m SimpleHTTPServer "$port" &
server_pid=$!
# 2. Trap any killing of this process so that we kill the backgrounded server
;(function () {
const on = window.addEventListener
let parent = null
const _post = function () {
parent.postMessage(
{
type: 'FRAME_HEIGHT',
height: document.documentElement.scrollHeight,
},