examples/todo/js/modules/list.js
function() {
			// Clear the todo list first
			this.clearList();

			var todos = todosDB.getList(),
				todo;

			// Render todos - factor in the current filter as well
			for (var i = 0, len = todos.length; i < len; i++) {
				todo = todos[i];

				if (!filter
						|| (filter === 'incomplete' && !todo.completed)
						|| (filter === 'complete' && todo.completed)) {
					this.addTodoItem(todo.id, todo.title, todo.completed);

				}
			}
		}
function() {
			// Clear the todo list first
			this.clearList();

			var todos = todosDB.getList(),
				todo;

			// Render todos - factor in the current filter as well
			for (var i = 0, len = todos.length; i < len; i++) {
				todo = todos[i];

				if (!filter
						|| (filter === 'incomplete' && !todo.completed)
						|| (filter === 'complete' && todo.completed)) {
					this.addTodoItem(todo.id, todo.title, todo.completed);

				}
			}
		}
function ( ) { // Clear the todo list first this . clearList ( ) ; var todos = todosDB . getList ( ) , todo ; // Render todos - factor in the current filter as well for ( var i = 0 , len = todos . length ; i < len ; i ++ ) { todo = todos [ i ] ; if ( ! filter || ( filter === 'incomplete' && ! todo . completed ) || ( filter === 'complete' && todo . completed ) ) { this . addTodoItem ( todo . id , todo . title , todo . completed ) ; } } }
Renders all todos in the todos db
@returns {void}
Renders all todos in the todos db