class Book { constructor(name, price) { this.name = name this.price = price } } function appendBooks() { var bookList = [new Book("1", 1),new Book("2", 2)] for (book in bookList) { var ul = document.createElement("ul") ul.classList.add("clearfix", "item-content") ul.innerHTML = '
Apple/苹果 iPhone 11 Pro
¥8699.00
\¥17398.00
\