Skip to content

Instantly share code, notes, and snippets.

@mjfathinia
mjfathinia / simple-js-inheritance.js
Created October 2, 2012 01:51
Simple JavaScript Inheritance By John Resig
/* Simple JavaScript Inheritance
* By John Resig http://ejohn.org/
* MIT Licensed.
*/
// Inspired by base2 and Prototype
(function(){
'use strict';
var initializing = false, fnTest = /xyz/.test(function(){xyz;}) ? /\b_super\b/ : /.*/, exfunc;
// The base Class implementation (does nothing)
this.Class = function(){};
@mjfathinia
mjfathinia / dabblet.css
Created January 11, 2012 01:48
Write less, Do More by HTML/CSS
/**
* Write less, Do More by HTML/CSS
*/
ul {list-style:none;}
ul li { border-bottom:1px solid #ddd;}
ul li article {position:relative; padding:5px 0 10px 230px; min-height:150px;}
article h3 {margin-top:10px;}
ul li article h3 img {position:absolute; left:0; top:0; border:5px solid transparent; box-shadow:0 0 10px rgba(0,0,0,0.5); border-radius:5px;}
article h3 a {text-decoration:none; color:#003399;}