NOTE: This post now lives (and kept up to date) on my blog: http://hakunin.com/rails3-load-paths
Do nothing. All files in this dir are eager loaded in production and lazy loaded in development by default.
potentially useful features/ tweaks: | |
1. persistent node toggle across searches | |
2. node toggles expand AND highlight (alt color?) | |
3. opacity darken bg for nested containers | |
4. search expressions (key="foo" value=2 AND value=5) | |
// key is exactly "foo" OR value contains both 2 and 5 |
import Component from '@ember/component'; | |
import { computed } from '@ember/object'; | |
import { later, next } from '@ember/runloop'; | |
import $ from 'jquery'; | |
const TEMP_DELAY = 3000; | |
const SLIDE_DELAY = 300; | |
const FADE_IN_DELAY = SLIDE_DELAY * 1.3; | |
const FADE_OUT_DELAY = SLIDE_DELAY * 0.7; |
// Add on element with overflow | |
-webkit-mask-image: -webkit-radial-gradient(white, black); |
var mobileCheck = { | |
ios: (function(){ | |
return navigator.userAgent.match(/iPhone|iPad|iPod/i); | |
}()), | |
android: (function(){ | |
return navigator.userAgent.match(/Android/i); | |
}()), | |
blackBerry: (function(){ | |
return navigator.userAgent.match(/BB10|Tablet|Mobile/i); | |
}()), |
NOTE: This post now lives (and kept up to date) on my blog: http://hakunin.com/rails3-load-paths
Do nothing. All files in this dir are eager loaded in production and lazy loaded in development by default.
#!/usr/bin/env sh | |
rm out*.jpg | |
rm out*.gif | |
ffmpeg -y -i 13040065.mp4 -t 1 -filter:v transpose=1,scale=400:-1,deshake,crop=400:400 out%02d.jpg | |
for file in *.jpg; do | |
convert $file ${file%.*}.gif | |
done | |
gifsicle --delay=5 --colors 256 --loop out*.gif > final.gif |
/** | |
* Converts an RGB color value to HSL. Conversion formula | |
* adapted from http://en.wikipedia.org/wiki/HSL_color_space. | |
* Assumes r, g, and b are contained in the set [0, 255] and | |
* returns h, s, and l in the set [0, 1]. | |
* | |
* @param Number r The red color value | |
* @param Number g The green color value | |
* @param Number b The blue color value | |
* @return Array The HSL representation |
# config/locales/en.yml | |
en: | |
exception: | |
show: | |
not_found: | |
title: "Not Found" | |
description: "The page you were looking for does not exists." | |
internal_server_error: | |
title: "Internal Server Error" |
# -*- encoding : utf-8 -*- | |
set :assets_dependencies, %w(app/assets lib/assets vendor/assets Gemfile.lock config/routes.rb) | |
namespace :deploy do | |
namespace :assets do | |
desc <<-DESC | |
Run the asset precompilation rake task. You can specify the full path \ | |
to the rake executable by setting the rake variable. You can also \ |