Skip to content

Instantly share code, notes, and snippets.

View mike-engel's full-sized avatar
👻
Writing code, maybe ¯\_(ツ)_/¯

Mike Engel mike-engel

👻
Writing code, maybe ¯\_(ツ)_/¯
View GitHub Profile
@DavidKuennen
DavidKuennen / minimal-analytics-snippet.js
Last active March 28, 2024 01:45
Minimal Analytics Snippet
(function (context, trackingId, options) {
const history = context.history;
const doc = document;
const nav = navigator || {};
const storage = localStorage;
const encode = encodeURIComponent;
const pushState = history.pushState;
const typeException = 'exception';
const generateId = () => Math.random().toString(36);
const getId = () => {
@robatwilliams
robatwilliams / HtmlModuleScriptWebpackPlugin.js
Created December 3, 2017 23:25
Plugin to create HTML page which loads ES5 or ES6 build according to browser capability
const { concat, mapKeys, merge, uniq } = require('lodash');
/**
* Tweaked from original by Mike Engel
* https://github.com/jantimon/html-webpack-plugin/issues/782#issuecomment-331229728
*
* Use this with multiple Webpack configurations that generate different builds
* for modern and legacy browsers. But use the same instance of the plugin in both configurations.
*
* It keeps track of assets seen in each build configuration, and appends script tags for
@sdnts
sdnts / example.md
Last active January 10, 2023 20:50
Postman pm.sendRequest example

To send a request via the sandbox, you can use pm.sendRequest.

pm.test("Status code is 200", function () {
    pm.sendRequest('https://postman-echo.com/get', function (err, res) {
        pm.expect(err).to.not.be.ok;
        pm.expect(res).to.have.property('code', 200);
        pm.expect(res).to.have.property('status', 'OK');
    });
});
@inamiy
inamiy / SwiftElmFrameworkList.md
Last active March 11, 2024 10:20
React & Elm inspired frameworks in Swift
@betaorbust
betaorbust / README.md
Last active July 21, 2018 19:57
ES2015 fallback check for Progressive Transpilation

ES2015 Syntax Check for use with Progressive Transpilation

The attached file file spits out a string for direct injection into the head of a page, which will be a lightweight test of the ability to parse and run ES2015 syntax.

Unminified version

This is the original source for the test-case below:

class ಠ_ಠ extends Array{
@jessicard
jessicard / macarons.md
Last active February 3, 2023 03:53
Macarons!

Basic macaron shell recipe

  • This will make approximately 100 shells, or about 4 dozen cookies
  • When practicing, I generally half this recipe to only make 1 sheet of cookies
  • When making macarons, you will generally flavor the filling but not the shells
  • You want to make the macarons the day before the event. You will store them in the refrigerator over night, and then take them out a few hours before to come to room temperature. This is because macarons are best when "ripened", or allowed to sit for at least one night and have the filling seep into the shells a bit. Otherwise, straight out of the oven, they can be too crunchy or hard
  • Macarons shells freeze well! Filled macarons can also freeze well depending on the filling. Buttercream fillings freeze great. Put the cookies into an airtight container before freezing
  • Everyones baking temperature and baking time vary depending on their oven - you might have to experiment a bit!
  • _I always separate egg whites myself by cracking the egg, p
@alirobe
alirobe / reclaimWindows10.ps1
Last active April 26, 2024 17:59
This Windows 10 Setup Script turns off a bunch of unnecessary Windows 10 telemetery, bloatware, & privacy things. Not guaranteed to catch everything. Review and tweak before running. Reboot after running. Scripts for reversing are included and commented. Fork of https://github.com/Disassembler0/Win10-Initial-Setup-Script (different defaults). N.…
###
###
### UPDATE: For Win 11, I recommend using this tool in place of this script:
### https://christitus.com/windows-tool/
### https://github.com/ChrisTitusTech/winutil
### https://www.youtube.com/watch?v=6UQZ5oQg8XA
### iwr -useb https://christitus.com/win | iex
###
###
@staringispolite
staringispolite / asciiputsonglasses
Last active March 22, 2024 06:39
Ascii art sunglasses meme
Puts on glasses:
(•_•)
( •_•)>⌐■-■
(⌐■_■)
Takes off glasses ("mother of god..."):
(⌐■_■)
( •_•)>⌐■-■
@montlebalm
montlebalm / .vimrc
Created September 25, 2014 16:28
Get it on. Vim till the break of dawn.
set nocompatible
filetype off
filetype plugin indent off
" -----------------------------------------------------------------------------
" Plugins
" -----------------------------------------------------------------------------
" Set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/vundle.vim/
@pburtchaell
pburtchaell / styles.css
Last active February 25, 2024 12:24
VH and VW units can cause issues on iOS devices. To overcome this, create media queries that target the width, height, and orientation of iOS devices.
/**
* VH and VW units can cause issues on iOS devices: http://caniuse.com/#feat=viewport-units
*
* To overcome this, create media queries that target the width, height, and orientation of iOS devices.
* It isn't optimal, but there is really no other way to solve the problem. In this example, I am fixing
* the height of element `.foo` —which is a full width and height cover image.
*
* iOS Resolution Quick Reference: http://www.iosres.com/
*/