Skip to content

Instantly share code, notes, and snippets.

View flexbox's full-sized avatar

David Leuliette flexbox

View GitHub Profile
@bradfrost
bradfrost / SassMeister-input.scss
Created December 11, 2013 05:24
Generated by SassMeister.com.
// ----
// Sass (v3.3.0.rc.1)
// Compass (v0.13.alpha.10)
// ----
@function randomColor($format:NULL) {
$red: random(256);
$green: random(256);
$blue: random(256);
@return rgb($red, $green, $blue);
mymodule {
@at-root {
.#{&}-header { ... }
.#{&}-footer { ... }
.#{&}-body {
a { ... }
span { ... }
p { ... }
}
}
/* The Grid ---------------------- */
.lt-ie9 .row { width: 940px; max-width: 100%; min-width: 768px; margin: 0 auto; }
.lt-ie9 .row .row { width: auto; max-width: none; min-width: 0; margin: 0 -15px; }
.lt-ie9 .row.large-collapse .column,
.lt-ie9 .row.large-collapse .columns { padding: 0; }
.lt-ie9 .row .row { width: auto; max-width: none; min-width: 0; margin: 0 -15px; }
.lt-ie9 .row .row.large-collapse { margin: 0; }
.lt-ie9 .column, .lt-ie9 .columns { float: left; min-height: 1px; padding: 0 15px; position: relative; }
.lt-ie9 .column.large-centered, .columns.large-centered { float: none; margin: 0 auto; }
@adamstac
adamstac / _font-smoothing.scss
Created February 27, 2013 15:46
WebKit font-smoothing Sass mixin
// WebKit font-smoothing
//------------------------------------------------
// References:
//
// 1. http://maxvoltar.com/sandbox/fontsmoothing/
// 2. http://maxvoltar.com/archive/-webkit-font-smoothing
//
// Values: none, antialiased (default), subpixel-antialiased
//
@desandro
desandro / require-js-discussion.md
Created January 31, 2013 20:26
Can you help me understand the benefit of require.js?

I'm having trouble understanding the benefit of require.js. Can you help me out? I imagine other developers have a similar interest.

From Require.js - Why AMD:

The AMD format comes from wanting a module format that was better than today's "write a bunch of script tags with implicit dependencies that you have to manually order"

I don't quite understand why this methodology is so bad. The difficult part is that you have to manually order dependencies. But the benefit is that you don't have an additional layer of abstraction.


@flexbox
flexbox / markdown-shortcut
Last active December 27, 2016 14:04
Here is all the markup for markdown text files
Title
# h1
## h2
### h3
#### h4
##### h5
###### h6
@flexbox
flexbox / imgScale.css
Last active December 11, 2015 20:18
zoom img using CSS3 transition & transform
.map {
display: block;
overflow: hidden;
}
.map span{
display: block;
height: 250px;
background:url(../img/map.jpg) no-repeat top left;
transition: transform 0.2s linear 0s;
@aarongustafson
aarongustafson / undoing-tables.html
Last active May 17, 2024 04:31
A Strategy for Undoing Tables
<table>
<thead>
<tr>
<th scope="col">Name</th>
<th scope="col">Email</th>
<th scope="col">Dept, Title</th>
<th scope="col">Phone</th>
</tr>
</thead>
<tbody>
@SamMarkiewicz
SamMarkiewicz / pRemover.js
Last active October 12, 2015 23:57
Removes <p> around <img> for Tumblr text
// Create the var according to your needs :
var wrappedImg = $('[higher-selector-that-contains-img]').find('img')
wrappedImg.closest('p > *').unwrap(); //Allow p suppression even if the structure changes - i.e if you put link on your img
// Exemple :
// var wrappedImg = $('section').find('img')
// wrappedImg .unwrap('p');
@Integralist
Integralist / 1. Example.scss
Created October 22, 2012 14:10
Sass Mixin for CSS3 Animations
@include keyframe(fadeout) {
0% {
opacity: 1;
}
100% {
opacity: 0;
}
}