Заказать
В корзину
{"ScriptPreparationCode":"var sectionCards = document.querySelector(\u0027.cards\u0027);\r\nvar templateCards = document.querySelector(\u0027#product-card-template\u0027);\r\nvar cardInnerHTML = \u0060\u003Cdiv class=\u0022product-card\u0022\u003E\r\n \u003Cimg class=\u0022product-card__photo\u0022 src=\u0022#\u0022 alt=\u0022\u0022 /\u003E\r\n \u003Cdiv class=\u0022product-card__text-container\u0022\u003E\r\n \u003Ch3 class=\u0022product-card__title\u0022\u003E\u003C/h3\u003E\r\n \u003Cp class=\u0022product-card__cost\u0022\u003E\u003C/p\u003E\r\n \u003C/div\u003E\r\n \u003Cdiv class=\u0022product-card__button-container\u0022\u003E\r\n \u003Cbutton class=\u0022product-card__order-button\u0022 type=\u0022button\u0022\u003E\u0417\u0430\u043A\u0430\u0437\u0430\u0442\u044C\u003C/button\u003E\r\n \u003Cbutton class=\u0022product-card__basket-button\u0022 type=\u0022button\u0022\u003E\u0412 \u043A\u043E\u0440\u0437\u0438\u043D\u0443\u003C/button\u003E\r\n \u003C/div\u003E\r\n \u003C/div\u003E\u0060;","TestCases":[{"Name":"Paste node template","Code":"for (let index = 0; index \u003C 10; index\u002B\u002B) {\r\n var cardTemplate = templateCards.content.querySelector(\u0027.product-card\u0027).cloneNode(true);\r\n sectionCards.prepend(cardTemplate);\r\n}","IsDeferred":false},{"Name":"Paste ready html","Code":"var result;\r\n\r\nfor (let index = 0; index \u003C 10; index\u002B\u002B) {\r\n result \u002B= cardInnerHTML\r\n}\r\n\r\nsectionCards.innerHTML = result;\r\n","IsDeferred":false}]}