Skip to content

Instantly share code, notes, and snippets.

@yuanyan
yuanyan / glitch.scss
Created September 11, 2014 15:55
Glitch effects
.glitch{
color:white;
font-size:100px;
position:relative;
width:400px;
margin:0 auto;
}
@keyframes noise-anim{
$steps:20;
@for $i from 0 through $steps{
@yuanyan
yuanyan / loadStyles.js
Created September 19, 2014 14:45
Injects the CSS into the <head> DOM node.
/**
* Injects the CSS into the <head> DOM node.
*
* @param {String} css CSS string to add to the <style> tag.
* @param {Document} doc document instance to use.
*/
function loadStyles(css, doc) {
// default to the global `document` object
if (!doc) doc = document;