1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
|
const optionForm = document.createElement('form');
const optionLabel = document.createElement('label');
const optionSelect = document.createElement('select');
const optionValeur = document.createElement('option');
cameraDiv.appendChild(optionForm);
optionForm.appendChild(optionLabel);
optionForm.appendChild(optionSelect);
optionSelect.appendChild(optionValeur);
optionLabel.textContent = 'Choix';
for (let i = 0; i <cameras.lenses.length; i++) {
console.log(cameras.lenses[i])
optionSelect.appendChild(optionValeur)
optionValeur.textContent = cameras.lenses;
console.log(cameras.lenses)
} |