Skip to content

Instantly share code, notes, and snippets.


Please include a repro

You probably arrived here because of a curt message in response to an issue you filed on a repo that I contribute to. Sorry about that (particularly if you filed the issue long ago and have been waiting patiently for a response). Let me explain:

I work on a lot of different open source projects. I really do like building software that makes other people's lives easier, but it's crazy time-consuming. One of the most time-consuming parts is responding to issues. A lot of OSS maintainers will bend over backwards to try and understand your specific problem and diagnose it, to the point of setting up new test projects, fussing around with different Node versions, reading the documentation for build tools that we don't use, debugging problems in third party dependencies that appear to be involved in the problem... and so on. I've personally spent hundreds of hours of my free time doing these sorts of things to try and help people out, because I want to be a responsible maintainer and I

nrollr /
Last active Aug 8, 2022
Enable SSL in Apache for 'localhost' (OSX, El Capitan)

Enable SSL in Apache (OSX)

The following will guide you through the process of enabling SSL on a Apache webserver

  • The instructions have been verified with OSX El Capitan (10.11.2) running Apache 2.4.16
  • The instructions assume you already have a basic Apache configuration enabled on OSX, if this is not the case feel free to consult Gist: "Enable Apache HTTP server (OSX)"

Apache SSL Configuration

Create a directory within /etc/apache2/ using sudo mkdir /etc/apache2/ssl
Next, generate two host keys:

leymannx / gulpfile.js
Last active Aug 4, 2022
Gulp Sass with autoprefixer and minify.
View gulpfile.js
var gulp = require('gulp'),
sass = require('gulp-sass'),
rename = require('gulp-rename'),
cssmin = require('gulp-cssnano'),
prefix = require('gulp-autoprefixer'),
plumber = require('gulp-plumber'),
notify = require('gulp-notify'),
sassLint = require('gulp-sass-lint'),
sourcemaps = require('gulp-sourcemaps');
// Temporary solution until gulp 4
samthor / safari-nomodule.js
Last active Jun 23, 2022
Safari 10.1 `nomodule` support
View safari-nomodule.js
* Copyright 2017 Google LLC
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
* Unless required by applicable law or agreed to in writing, software
Jakobud / _map-sort.scss
Last active Jun 20, 2022
Sort a SASS map
View _map-sort.scss
/// map-sort
/// Sort map by keys
/// @param $map - A SASS map
/// @returns A SASS map sorted by keys
/// @requires function list-sort
/// @author Jake Wilson <>
@function map-sort($map) {
$keys: list-sort(map-keys($map));
$sortedMap: ();
@each $key in $keys {
kevingessner / parent.htm
Created May 17, 2013
Detect browser zoom in javascript 'zoom' event is triggered on window on every browser zoom change. No polling!
View parent.htm
<script src=""></script>
<iframe id="frame" style="width: 250px; border: solid 1px red;" ></iframe>
<script type="text/javascript">
var elFrame = $('#frame')[0];
$(elFrame.contentWindow).resize(function() {
View Pricing Plans Design Checklist
1. Highlight a recommended option,

2. Allow users to switch currency (€/$/£)

3. Allow users to switch pricing monthly/yearly

4. Keep the entire pricing plan area clickable

5. Use slider to calculate how much a user would save

6. Provide free first month for good engagement

7. Prominently highlight testimonials prominently

8. Repeating call to action on top and bottom

9. Sell benefits instead of features

10. Indicate that users can cancel any time

guenthertheilen / gist:8401080
Created Jan 13, 2014
Install Composer on Managed Hosting at Domainfactory
View gist:8401080

Install Composer on Managed Hosting at Domainfactory

Step 1:

Log in to your Managed Hosting Server via SSH

Step 2:

Add these two lines to .bashrc:

CITguy / custom-task.js
Last active Mar 3, 2021
Basic pattern for creating a custom Transform stream for use with gulp tasks.
View custom-task.js
var gulp = require('gulp');
var myTransform = require('./myTransform');
gulp.task('foobar', function (){
return gulp.src("foobar.js")