Skip to content

Instantly share code, notes, and snippets.

Avatar

Trevor Owens owenstrevor

View GitHub Profile
@owenstrevor
owenstrevor / dev.exs
Last active Feb 27, 2019
Phoenix Webpack.config.js Auto-Reload (Phoenix 1.4.1)
View dev.exs
# the below starts on line 9 of dev.exs, the rest of the file remains unchanged
# Just npm install nodemon globally with the below command, no need to add it to package.json
# $ npm install --global nodemon
# lines 13 to 16 below are what I added to get this to work
# lines 17 to 23 are already there with a new install (do not delete them, just add nodemon stuff before it)
config :my_app, MyAppWeb.Endpoint,
http: [port: 4000],
debug_errors: true,
code_reloader: true,
@owenstrevor
owenstrevor / css-comparison.csv
Created Feb 19, 2019 — forked from primaryobjects/css-comparison.csv
A comparison of CSS library sizes.
View css-comparison.csv
Name Version Size (uncompressed) Size (minified) Size (gzipped) URL
Bootstrap v3.3.7 143 KB 117 KB 20 KB http://getbootstrap.com/css/
Bootstrap v4.0.0 187 KB 147 KB 20 KB https://v4-alpha.getbootstrap.com/
Materialize v3.0 114 KB 90 KB 18 KB http://materializecss.com/
Material Design Lite v1.3.0 350 KB 137 KB 21 KB https://getmdl.io/
mini.css v2.1 47 KB 36 KB 7 KB https://chalarangelo.github.io/mini.css/
Semantic UI v2.2.6 730 KB 550 KB 95 KB https://semantic-ui.com/
Foundation v3.0 90 KB 64 KB 12 KB http://foundation.zurb.com/
Pure CSS v0.6.2 80 KB 17 KB 3.8 KB https://purecss.io/
Picnic CSS v6.3.2 55 KB 38 KB 7 KB https://picnicss.com
@owenstrevor
owenstrevor / gist:d18dd433d00051183dcacbcfb74cd39d
Created Oct 18, 2017
ChannelMergerNode HTML5 Audio - Play in both speakers
View gist:d18dd433d00051183dcacbcfb74cd39d
var audioCtx = new (window.AudioContext || window.webkitAudioContext)();
var myAudio = document.querySelector('audio');
var source = audioCtx.createMediaElementSource(myAudio);
var merger = audioCtx.createChannelMerger(1);
source.connect(merger);
merger.connect(audioCtx.destination);
@owenstrevor
owenstrevor / convert scss to sass
Last active May 29, 2016 — forked from pedrogpimenta/convert sass to scss
Convert SCSS to SASS and delete .scss files (applies to all files in current folder)
View convert scss to sass
sass-convert -R ./ -F scss -T sass
find . -name "*.scss" -type f -delete