const $items = $('.order__desc');
$items.click(function() {
$('.order__inner').eq($items.index($(this))).show();
});
document.getElementById("AAA").onmousedown = (e) => this.mouse_down(e);
document.onmousemove = () => this.manipulate_this_element();
resolve(response[i][0]);
const { response, execute_errors } = await request(code);
for (let i = 0, len = response.length; i < len; i++) {
const { resolve, reject } = queuePart[i];
if (response[i] === false) {
reject(execute_errors.shift());
} else {
resolve(response[i]);
}
};
const promiseList = [
new Promise(resolve => setTimeout(resolve, 200, 15)),
new Promise(resolve => setTimeout(resolve, 600, 17)),
new Promise(resolve => setTimeout(resolve, 500, 42))
];
async function* promiseGenerator(arrPromise) {
const result = [];
const push = (val) => result.push(val);
const promises = arrPromise.map((promise) => promise.then(push));
await Promise.all(promises);
for (let i = result.length - 1; i >= 0; --i) {
yield result[i];
}
}
const data = list.reduce((acc, {title, part}) => {
acc[part] = acc[part] || [];
acc[part].push(title);
return acc;
}, {});
Object.entries(data).forEach(([part, titles]) => {
[part, ...titles].forEach((item) => {
const div = document.createElement('div');
div.textContent = item;
document.body.appendChild(div);
});
});
let option = select.getElementsByClassName('label')[0];
илиlet option = select.querySelector('.label');