Skip to content

Instantly share code, notes, and snippets.

View juandopazo's full-sized avatar

Juan Dopazo juandopazo

View GitHub Profile
@mattparker
mattparker / 1. ArrayList with events.js
Created September 30, 2010 12:47
YUI3: A simple example adding events to Base extensions augmented by ArrayList
/**
* Y.ArrayListEvents fires some events for ArrayList.
* 8/10/10: update - Added events for everything, pretty much,
* and added nicer signatures for subscribers
* Also changed the name slightly (from Y.ArrayListEventProvider)
*/
Y.ArrayListEvents = Y.Base.create(
'arraylistevents',
Y.Plugin.Base,
@lsmith
lsmith / a.js
Created May 22, 2011 13:57
Using YUI 3's groups config to support fetching non-YUI module js files ala requireJS pathing or explicit url
We couldn’t find that file to show.
@DmitrySoshnikov
DmitrySoshnikov / class.js
Created November 1, 2011 14:08
Class lib sugar for JS
/**
* class.js
* @author Dmitry A. Soshnikov
*/
function Class(params) {
/**
* Constructor function
* If not specified, use default
@derek
derek / gist:1389403
Created November 23, 2011 18:09
YUI 3 Button Proposal

YUI Button

Goal

To introduce a new Button component for YUI 3 that addresses the following user stories

  • "I want buttons on my site to look consistent & attractive."
  • "I want to be able to programmatically control buttons in my application."
  • "I want to my buttons to be intelligent and interact with one another in groups."
  • "I want my application to be able to dynamically generate buttons."
@davglass
davglass / unix.txt
Created December 7, 2011 17:40
YUIDoc with 3.5.0 install instructions
Unix Install Instructions (until it's available via npm)
git clone git://github.com/yui/yui3.git
git clone git://github.com/davglass/yuidocjs.git
cd yui3/src/yui
make npm
cd ../../../yuidocjs
git checkout -t origin/3.5.0
@lsmith
lsmith / gist:2375130
Created April 13, 2012 08:37
Ye Olde brainstorm about IO API

Data normalization API proposal

Data API normalization/centralization in three layers

  1. transport layer

  2. transaction layer

  3. encapsulated configuration layer (aka Resource/DataSource)

  4. Transport layer

@rwaldron
rwaldron / device.js
Created May 10, 2012 16:21
Fat Arrows and Classes-as-Prototype-sugar make a beautiful future for JavaScript
var stream = require("fake-stream-lib"),
Emitter = require("events").EventEmitter,
util = require("util");
// Today...
function Device( opts ) {
this.value = null;
@juandopazo
juandopazo / gist:3193926
Created July 28, 2012 16:34
Server Y.Router
YUI.add('router', function (Y) {
/**
Provides URL-based routing for Node
@module app
@submodule router
@since 3.4.0
**/
var QS = Y.QueryString,
@juandopazo
juandopazo / gist:5405383
Last active December 16, 2015 08:19
Storage module design and API for review

Storage

Motivation

There are 3 major types of storage is browsers up to date:

  • IndexedDB. The future.
  • localStorage. Limited in size and can be observed through the storage event.
  • WebSQL. Dropped by the W3C but it's still very present in the wild, with notable platforms like iOS and PhoneGap.
test 123