Skip to content

Instantly share code, notes, and snippets.

Avatar

mparaiso Mparaiso

View GitHub Profile
@Mparaiso
Mparaiso / apiexamples.js
Created May 9, 2012 — forked from jrburke/apiexamples.js
Description of browser-friendly module APIs: AMD and Loader Plugins
View apiexamples.js
//*******************************************
// 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 — forked from bentruyman/jquery-pubsub.js
Simple Pub/Sub Implementation for jQuery
View jquery-pubsub.js
/*
* 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 Jun 12, 2012 — forked from scottjehl/hideaddrbar.js
Normalized hide address bar for iOS & Android
View hideaddrbar.js
/*
* 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 Jul 24, 2012
three.js, TweenLite , Coordinates.js
View main.js
var camera,
scene,
renderer,
group,
grid,
wave ,
mesh,
currentLayout,
container,
layoutNames,
@Mparaiso
Mparaiso / ant.properties
Created Aug 2, 2012
hello-ant-js a simple ant configuration exemple
View ant.properties
css_dir = css
js_dir = js
assets_dir = assets
@Mparaiso
Mparaiso / Configuration.php
Created Sep 19, 2012 — forked from Lumbendil/Configuration.php
"Recursive" configuration in Symfony2 Config Component
View Configuration.php
<?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 Sep 19, 2012 — forked from ziadoz/awesome-php.md
Awesome PHP Libraries
View awesome-php.md

Awesome PHP Libraries

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

@Mparaiso
Mparaiso / markdown.md
Created Oct 7, 2012
Markdown cheat sheet
View markdown.md

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

View Add field to an existing Django app 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 Nov 30, 2012 — forked from twfarland/currycompose.coffee
Currying / Function composition in coffeescript
View currycompose.coffee
arr = Array::
arrSlice = arr.slice
curry = ->
args = arrSlice.call arguments
->
args2 = arrSlice.call arguments
args[0].apply @, args.slice(1).concat(args2)
sum = ->