This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Creature | |
def self.metaclass; class << self; self; end; end | |
def self.traits(*arr) | |
return @traits if arr.empty? | |
#1. Set up accessors for each variable | |
attr_accessor *arr |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$("#main-button").tooltip(); | |
$("#main-button").click(function() { | |
$(this).tooltip('hide'); | |
// css-endringer eller sette på ny klasse | |
$(".tooltip-inner").css('background-color', 'red'); | |
$(this).tooltip('show'); | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env sh | |
## | |
# This is script with usefull tips taken from: | |
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx | |
# | |
# install it: | |
# curl -sL https://raw.github.com/gist/2108403/hack.sh | sh | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* ----------------------------------------------------------------------- */ | |
/* */ | |
/* Improved upon a mixin from 37signals and combined */ | |
/* with these numbers from marc. */ | |
/* */ | |
/* 37signals-version: */ | |
/* http://37signals.com/svn/posts/3271-easy-retina-ready-images-using-scss */ | |
/* */ | |
/* @kimroen */ | |
/* */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Pido-knapp | |
* The first commented line is your dabblet’s title | |
*/ | |
html { | |
background: linear-gradient(top, white, hsl(0,0%,95%)) no-repeat; | |
min-height: 100%; | |
font-family: sans-serif; | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function (global) { | |
"use strict"; | |
function empty(obj) { | |
var key; | |
for (key in obj) if (obj.hasOwnProperty(key)) return false; | |
return true; | |
} | |
var Ember = global.Ember, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ------------------------------------------------------------------------------ | |
# FILE: ember.plugin.zsh | |
# DESCRIPTION: oh-my-zsh ember plugin file. | |
# AUTHOR: Will Meldon ([email protected]) | |
# VERSION: 0.0.1 | |
# ------------------------------------------------------------------------------ | |
# Based (heavily) on composer.plugin.zsh | |
# | |
# Ember basic command completion | |
_ember_get_command_list () { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
model: function() { | |
return request(/* url */); | |
}, | |
setupController: function(controller, model) { | |
// This is the function that normally sets the result of `model` to the `model` property on the controller | |
controller.set('tacos', model.tacos); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Ember from 'ember'; | |
export default Ember.Controller.extend({ | |
appName:'Ember Twiddle', | |
queryParams: ['name'], | |
name: 'Kim' | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Let's get some color going! | |
red=$'\e[1;31m' | |
grn=$'\e[1;32m' | |
end=$'\e[0m' | |
# cd to cwd of the script (presumably in it's proper location) | |
cd "$(dirname "$0")" | |
printf "\nInstalling Sketch templates..." |
OlderNewer