diff --git a/.goutputstream-KEI9FZ b/.goutputstream-KEI9FZ new file mode 100644 index 0000000..7f3011c --- /dev/null +++ b/.goutputstream-KEI9FZ @@ -0,0 +1,41 @@ +"use strict"; + +console.log("App"); + +let addForm = document.getElementById("addFormElement"); +addForm.addEventListener("submit", addBook); + +let bookTable = document.getElementById("bookTableBody"); + +let lastBookId = 0; +function genBookId() { + return lastBookId++; +} + +function addBook(event){ + event.preventDefault(); + console.log("Add Book", event.target.bookTitle.value); + let bookId = genBookId(); + let row = ` +