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 Teaser extends React.Component { | |
render() { | |
var model = this.props.model; | |
return ( | |
<article className="teaser"> | |
<TeaserLink link={model.link}> | |
<Picture model={model.cover} type="square"/> | |
<div className="teaser__text"> | |
<TeaserCaption>{model.description}</TeaserCaption> | |
<div> |
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
'use strict'; | |
var React = require('react'); | |
var util = { | |
// findPos() by quirksmode.org | |
// Finds the absolute position of an element on a page | |
findPos: function (obj) { | |
/*jshint -W084 */ | |
var curleft = 0, |
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
Alex Aivars Worldwide! Site is forked from Jacob Åström Worldwide. | |
I help companies and organizations create what they normally don’t, | |
make things they didn’t know they could and do things they | |
wouldn’t think was possible. Always digital to most extent. | |
But then again – what isn’t? | |
☟ | |
Open for inquiries (or, at least, tea). |
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 zeroFill( number, width ) | |
{ | |
width -= number.toString().length; | |
if ( width > 0 ) | |
{ | |
return new Array( width + (/\./.test( number ) ? 2 : 1) ).join( '0' ) + number; | |
} | |
return number; | |
} | |
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
http = require("http") | |
q = require("querystring") | |
url = require("url") | |
server = http.createServer().listen 9006 | |
server.on "request", (req, res) -> | |
params = url.parse(req.url, true).query | |
callbackFn = "callback" | |
if params.url is undefined or params.url is "" |
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
################################################################################ | |
# | |
# [global] localstorage | |
# A simple cookie based polyfill for localStorage | |
# | |
################################################################################ | |
unless Modernizr.localstorage | |
window.localStorage = | |
length: 0 | |
setItem: (key, value) -> |
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
require 'rake/clean' | |
include ::Rake::DSL | |
BIN = "public_html" | |
HAML = FileList['**/*.haml'] | |
LESS = FileList['**/*.less'] | |
COFFEE = FileList['**/*.coffee'] | |
SASS = FileList['**/*.scss'] |
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
var canvas = document.getElementById('canvas1'); | |
var img = new Image; | |
var mst = new Image; | |
var mstSrc = "http://i.ytimg.com/vi/zNeaXKF0Eik/maxresdefault.jpg"; | |
var imgSrc = "http://www.goodwp.com/images/201303/goodwp.com_27776.jpg"; | |
const drawBackground = (canvas) => { | |
const ctx = canvas.getContext('2d'); | |
ctx.globalCompositeOperation = "source-over"; | |
ctx.globalAlpha = 1; |
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
export default function composeReducers(...reducers) { | |
return (state, action) => reducers.reduce((result, fn)=>fn(result, action), state); | |
} |
OlderNewer