Skip to content

Instantly share code, notes, and snippets.

@EchoFUN
EchoFUN / gist:7924659
Last active December 31, 2015 02:59
javascript事件系统
/**
* Example:
* var test = document.getElementById('test');
* evt(test).bind('custom', function() {
*
* })
*
* evt(test).trigger('custom');
*
*/
@EchoFUN
EchoFUN / step.js
Created June 15, 2012 04:52 — forked from leizongmin/step.js
JavaScript简单异步执行
/**
* 使用方法:
* step(function (data, next) {
* // step 1, do somethings...
* next(null, data);
* }, function (data, next) {
* // step 2, do somethings...
* next(null, data);
* }, function (err, data) {
* // callback
@EchoFUN
EchoFUN / step.js
Created June 15, 2012 04:47 — forked from leizongmin/step.js
JavaScript简单异步执行
/**
* 使用方法:
* step(function (data, next) {
* // step 1, do somethings...
* next(null, data);
* }, function (data, next) {
* // step 2, do somethings...
* next(null, data);
* }, function (err, data) {
* // callback