Skip to content

Instantly share code, notes, and snippets.

embrace the mystery

Ray Brown raybrownco

embrace the mystery
View GitHub Profile

Keybase proof

I hereby claim:

  • I am raybrownco on github.
  • I am raybrown ( on keybase.
  • I have a public key ASAjWu4kOFGRkQbkHct7Wr1Ur93e2rqxuvvEgirU1T-GNAo

To claim this, I am signing this object:

raybrownco / image_helpers.rb
Last active Jul 10, 2021
Inline SVG in Middleman
View image_helpers.rb
# Middleman - Inline SVG Helper
# ------------------------------------------------------------------------------
# Installation
# ------------
# 1. Save this file at `[project_root]/helpers/image_helpers.rb`
# 2. Open the project's Gemfile and add this line: `gem "oga"`
# 3. Run `bundle install` from the command line
# Note: Restart your local Middleman server (if it's running) before continuing
raybrownco / improved-keyframe-code.sass
Created Mar 20, 2012
I just stumbled across theCSSguru's animate mixin for Sass ( and found it very useful for including animations in my Sass files. However, I saw room for improvement in the keyframe code. Below is a comparison of the s
View improved-keyframe-code.sass
// Using a list to loop through each prefix and cut down on duplicated code
$keyframe-prefixes: (-webkit-keyframes, -moz-keyframes, -ms-keyframes, keyframes)
@each $prefix in $keyframe-prefixes
@#{$prefix} fadeIn
opacity: 0
opacity: 1
raybrownco / rem.scss
Created Aug 9, 2011
rem() is a Sass mixin that converts pixel values to rem values for whatever property is passed to it.
View rem.scss
* 'rem' is a Sass mixin that converts pixel values to rem values for whatever property is passed to it.
* It returns two lines of code — one of the regular pixel values (for IE), and another with the
* converted rem values (for everyone else). Special thanks to Chris Epstein (
* and Martin Bavio ( for the help and code!
* Sample input:
* .element {
* @include rem('padding',10px 0 2px 5px);
* }
raybrownco / wp-pods-vs-ee.php
Created Mar 13, 2011
This file is a comparison between WordPress/Pods and ExpressionEngine. It shows the syntax required to display a list of three featured books on a site's homepage.
View wp-pods-vs-ee.php
<!-- Featuring three books on a site's homepage -->
<!-- The Pods/WordPress way -->
<ul id="featured-books">
$book = new Pod('book');
$params = array(
'where'=>'t.show_on_homepage = 1',