Skip to content

Instantly share code, notes, and snippets.

View davydog187's full-sized avatar
🍍
Still Elixirin'

Dave Lucia davydog187

🍍
Still Elixirin'
View GitHub Profile
@thmsmlr
thmsmlr / wait_for.ex
Created December 26, 2024 21:20
ExUnit helper function to wait up to a timeout to determine whether a set of assertions completes. Perfect for testing async code
@default_timeout 100
@check_interval 10
# Test Helpers
defp wait_for(fun, timeout \\ @default_timeout) do
start_time = System.monotonic_time(:millisecond)
ref = make_ref()
try do
@DerKobe
DerKobe / console_log_filter_hack.js
Created May 26, 2017 08:19
Console log filter hack (because Chrome made a bad decision when removing the selective log filters)
// Taken from a post by Wojciech Zieliński at https://groups.google.com/forum/#!topic/google-chrome-developer-tools/kH3FiDLlsFg
const consoleDummy = { warn: () => {}, log: () => {}, error: () => {}, info: () => {} };
const { warn, log, error, info } = window.console || consoleDummy;
const $flags = {
warn: true,
log: true,
error: true,
info: true,
};
@robertknight
robertknight / Build.md
Last active July 8, 2022 01:32
Minimal Webpack DllPlugin example

Compile with:

webpack --config vendor.webpack.config.js
webpack --config app.webpack.config.js

Use with the following index.html

This is unmaintained, please visit Ben-PH/spacemacs-cheatsheet

Useful Spacemacs commands

  • SPC q q - quit
  • SPC w / - split window vertically
  • SPC w - - split window horizontally
  • SPC 1 - switch to window 1
  • SPC 2 - switch to window 2
  • SPC w c - delete current window
@staltz
staltz / introrx.md
Last active February 28, 2025 10:00
The introduction to Reactive Programming you've been missing
@jimbojsb
jimbojsb / gist:1630790
Created January 18, 2012 03:52
Code highlighting for Keynote presentations

Step 0:

Get Homebrew installed on your mac if you don't already have it

Step 1:

Install highlight. "brew install highlight". (This brings down Lua and Boost as well)

Step 2: