site/examples/todo/js/todos/todos.js
function (el, e) {
			var value = can.trim(el.val());
			if (e.keyCode === ENTER_KEY && value !== '') {
				new Models.Todo({
					text : value,
					complete : false
				}).save(function () {
					el.val('');
				});
			}
		}
function (el, e) {
			var value = can.trim(el.val());
			if (e.keyCode === ENTER_KEY && value !== '') {
				new Models.Todo({
					text : value,
					complete : false
				}).save(function () {
					el.val('');
				});
			}
		}
function ( el , e ) { var value = can . trim ( el . val ( ) ) ; if ( e . keyCode === ENTER_KEY && value !== '' ) { new Models . Todo ( { text : value , complete : false } ) . save ( function ( ) { el . val ( '' ) ; } ) ; } }
Listen for when a new Todo has been entered
Listen for when a new Todo has been entered