macabreb0b / backbone.TriggerHappy

Simple patch for debugging Backbone.js - prints out all of the 'trigger' events as they happen

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

#backbone.TriggerHappy

###Use

Include this file in your JavaScripts directory and require it in your manifest after you require backbone.js and before you initialize your Backbone app.

e.g., if you're using Rails with Backbone, add this line to your application.js file:

//= require backbone  
//= require backbone.TriggerHappy  
//= require your_app

All events will be printed to your web console as they are triggered, in the following format:

className (id): event

Class names include:

  • Model
  • Collection
  • View
  • Router

About

Simple patch for debugging Backbone.js - prints out all of the 'trigger' events as they happen


Languages

Language:JavaScript 100.0%