on line 107 of TodoStore.js:
/**
* @param {function} callback
*/
addChangeListener: function(callback) {
this.on(CHANGE_EVENT, callback);
},
link: https://github.com/facebook/flux/blob/master/examples/flux-todomvc/js/stores/TodoStore.js
The example is using the Node Events module, which defines EventEmitter. The two lines that show you what is going on are:
var EventEmitter = require('events').EventEmitter;
And…
var TodoStore = assign({}, EventEmitter.prototype, {