Skip to content

Instantly share code, notes, and snippets.

View juandopazo's full-sized avatar

Juan Dopazo juandopazo

View GitHub Profile
@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
// Here is a proposal for minimalist JavaScript classes, humbly offered.
// There are (at least) two different directions in which classes can be steered.
// If we go for a wholly new semantics and implementation, then fancier classical
// inheritance can be supported with parallel prototype chains for true inheritance
// of properties at both the class and instance level.
// If however, we keep current JavaScript prototype semantics, and add a form that
// can desugar to ES3, things must necessarily stay simpler. This is the direction
// I'm assuming here.
@nzakas
nzakas / gist:1164118
Created August 23, 2011 01:47
Ant target for autogenerating changelog based on Git tags
<!--
Ant target for autogenerating a changelog based on Git tags
Workflow:
1. Do all of your checkins for a given version.
2. When you're ready to officially create a new version, tag it using git tag, such as "git tag v0.3.0".
3. If you don't already have a file named CHANGELOG in the root directory, make one.
4. Run "ant changelog.update"
@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.
@Kilian
Kilian / annoying.js
Created January 6, 2011 15:04
How to be an asshole
/**
* Annoying.js - How to be an asshole to your users
*
* DO NOT EVER, EVER USE THIS.
*
* Copyright (c) 2011 Kilian Valkhof (kilianvalkhof.com)
* Visit https://gist.github.com/767982 for more information and changelogs.
* Visit http://kilianvalkhof.com/2011/javascript/annoying-js-how-to-be-an-asshole/ for the introduction and weblog
* Check out https://gist.github.com/942745 if you want to annoy developer instead of visitors
*
@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,