Commit d1198bb2 authored by Arthur Verschaeve's avatar Arthur Verschaeve

Spine: compile using latest coffee

parent 5acb4b96
// Generated by CoffeeScript 1.7.1
// Generated by CoffeeScript 1.9.1
(function() {
var TodoApp,
__bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; },
__hasProp = {}.hasOwnProperty,
__extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; };
bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; },
extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; },
hasProp = {}.hasOwnProperty;
TodoApp = (function(_super) {
TodoApp = (function(superClass) {
var ENTER_KEY;
__extends(TodoApp, _super);
extend(TodoApp, superClass);
ENTER_KEY = 13;
......@@ -30,10 +30,10 @@
};
function TodoApp() {
this.renderFooter = __bind(this.renderFooter, this);
this.toggleElems = __bind(this.toggleElems, this);
this.addAll = __bind(this.addAll, this);
this.addNew = __bind(this.addNew, this);
this.renderFooter = bind(this.renderFooter, this);
this.toggleElems = bind(this.toggleElems, this);
this.addAll = bind(this.addAll, this);
this.addNew = bind(this.addNew, this);
TodoApp.__super__.constructor.apply(this, arguments);
Todo.bind('create', this.addNew);
Todo.bind('refresh change', this.addAll);
......@@ -84,15 +84,15 @@
};
TodoApp.prototype.addAll = function() {
var todo, _i, _len, _ref, _results;
var i, len, ref, results, todo;
this.todos.empty();
_ref = this.getByFilter();
_results = [];
for (_i = 0, _len = _ref.length; _i < _len; _i++) {
todo = _ref[_i];
_results.push(this.addNew(todo));
ref = this.getByFilter();
results = [];
for (i = 0, len = ref.length; i < len; i++) {
todo = ref[i];
results.push(this.addNew(todo));
}
return _results;
return results;
};
TodoApp.prototype.toggleAll = function(e) {
......
// Generated by CoffeeScript 1.7.1
// Generated by CoffeeScript 1.9.1
(function() {
var __bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; },
__hasProp = {}.hasOwnProperty,
__extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; };
var bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; },
extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; },
hasProp = {}.hasOwnProperty;
window.Todos = (function(_super) {
window.Todos = (function(superClass) {
var ENTER_KEY, ESCAPE_KEY, TPL;
__extends(Todos, _super);
extend(Todos, superClass);
ENTER_KEY = 13;
......@@ -29,7 +29,7 @@
};
function Todos() {
this.render = __bind(this.render, this);
this.render = bind(this.render, this);
Todos.__super__.constructor.apply(this, arguments);
this.todo.bind('update', this.render);
this.todo.bind('destroy', this.release);
......
// Generated by CoffeeScript 1.7.1
// Generated by CoffeeScript 1.9.1
(function() {
var __hasProp = {}.hasOwnProperty,
__extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; };
var extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; },
hasProp = {}.hasOwnProperty;
window.Todo = (function(_super) {
__extends(Todo, _super);
window.Todo = (function(superClass) {
extend(Todo, superClass);
function Todo() {
return Todo.__super__.constructor.apply(this, arguments);
......@@ -27,14 +27,14 @@
};
Todo.destroyCompleted = function() {
var todo, _i, _len, _ref, _results;
_ref = this.completed();
_results = [];
for (_i = 0, _len = _ref.length; _i < _len; _i++) {
todo = _ref[_i];
_results.push(todo.destroy());
var i, len, ref, results, todo;
ref = this.completed();
results = [];
for (i = 0, len = ref.length; i < len; i++) {
todo = ref[i];
results.push(todo.destroy());
}
return _results;
return results;
};
return Todo;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment