//sample solution to script.js
$(document).ready(function(){
$('#button').click(function(){
var toAdd = $('input[name=checkListItem]').val();
//remember to click on the Add button when testing
$('.list').append("<div class='item'>" + toAdd + "</div>");
});
$(document).on('click','.item',function(){
$(this).remove();
});
});
No comments:
Post a Comment