Skip to content

Instantly share code, notes, and snippets.

View Mparaiso's full-sized avatar

mparaiso Mparaiso

View GitHub Profile
@Mparaiso
Mparaiso / apiexamples.js
Created May 9, 2012 01:44 — forked from jrburke/apiexamples.js
Description of browser-friendly module APIs: AMD and Loader Plugins
//*******************************************
// Level 1, basic API, minimum support
//*******************************************
/*
Modules IDs are strings that follow CommonJS
module names.
*/
//To load code at the top level JS file,
//or inside a module to dynamically fetch
@Mparaiso
Mparaiso / jquery-pubsub.js
Created May 16, 2012 04:13 — forked from bentruyman/jquery-pubsub.js
Simple Pub/Sub Implementation for jQuery
/*
* Simple Pub/Sub Implementation for jQuery
*
* Inspired by work from Peter Higgins (https://github.com/phiggins42/bloody-jquery-plugins/blob/master/pubsub.js)
*
* This is about the simplest way to write a pubsub JavaScript implementation for use with jQuery.
*/
(function( $ ) {
// Cache of all topics
@Mparaiso
Mparaiso / hideaddrbar.js
Created June 12, 2012 03:26 — forked from scottjehl/hideaddrbar.js
Normalized hide address bar for iOS & Android
/*
* Normalized hide address bar for iOS & Android
* (c) Scott Jehl, scottjehl.com
* MIT License
*/
(function( win ){
var doc = win.document;
// If there's a hash, or addEventListener is undefined, stop here
if( !location.hash && win.addEventListener ){
@Mparaiso
Mparaiso / main.js
Created July 24, 2012 12:15
three.js, TweenLite , Coordinates.js
var camera,
scene,
renderer,
group,
grid,
wave ,
mesh,
currentLayout,
container,
layoutNames,
@Mparaiso
Mparaiso / ant.properties
Created August 2, 2012 01:54
hello-ant-js a simple ant configuration exemple
css_dir = css
js_dir = js
assets_dir = assets
@Mparaiso
Mparaiso / Configuration.php
Created September 19, 2012 09:50 — forked from Lumbendil/Configuration.php
"Recursive" configuration in Symfony2 Config Component
<?php
namespace FashionWeb\DynamicRoutingBundle\DependencyInjection;
use Symfony\Component\Config\Definition\Builder\TreeBuilder;
use Symfony\Component\Config\Definition\ConfigurationInterface;
use Symfony\Component\Config\Definition\Builder\NodeDefinition;
/**
* This is the class that validates and merges configuration from your app/config files
@Mparaiso
Mparaiso / awesome-php.md
Created September 19, 2012 17:00 — forked from ziadoz/awesome-php.md
Awesome PHP Libraries

Awesome PHP Libraries

A list of amazingly awesome PHP libraries that you should be using:

@Mparaiso
Mparaiso / markdown.md
Created October 7, 2012 22:02
Markdown cheat sheet

Header 1

Header 2

Header 3 ### (Hashes on right are optional)

Header 4

Header 5

Markdown plus h2 with a custom ID ## {#id-goes-here}

Link back to H2

This is a paragraph, which is text surrounded by whitespace. Paragraphs can be on one

@Mparaiso
Mparaiso / Add field to an existing Django app with South
Created October 10, 2012 16:29 — forked from DaveEveritt/Add field to an existing Django app with South
quickly add field(s) to existing Django models with South
====================================================================
Simple-as-possible instructions to add a field (or more) using South
to an existing Django model with existing data.
====================================================================
Two versions:
1. Super-condensed (the bare minimum - jfdi)
2. Detailed-but-brief (if you want more information).
Notes:
@Mparaiso
Mparaiso / currycompose.coffee
Created November 30, 2012 00:01 — forked from twfarland/currycompose.coffee
Currying / Function composition in coffeescript
arr = Array::
arrSlice = arr.slice
curry = ->
args = arrSlice.call arguments
->
args2 = arrSlice.call arguments
args[0].apply @, args.slice(1).concat(args2)
sum = ->