k🥔
Size: a a a
k🥔
В
const findElement = (selector) => [document.querySelector(selector)].filter(Boolean)
const prop = (key) => (obj) => obj[key]
findElement('.output')
.map((output) => output.innerHTML = (
findElement('.first').map(prop('innerHTML'))
.concat(findElement('.second').map(prop('innerHTML')))
.filter(Boolean)
.join(', ')
))
S
const findElement = (selector) => [document.querySelector(selector)].filter(Boolean)
const prop = (key) => (obj) => obj[key]
findElement('.output')
.map((output) => output.innerHTML = (
findElement('.first').map(prop('innerHTML'))
.concat(findElement('.second').map(prop('innerHTML')))
.filter(Boolean)
.join(', ')
))
В
В
В
В
МГ
В
В
В
В
p
p
const findElement = (selector) => [document.querySelector(selector)].filter(Boolean)
const prop = (key) => (obj) => obj[key]
findElement('.output')
.map((output) => output.innerHTML = (
findElement('.first').map(prop('innerHTML'))
.concat(findElement('.second').map(prop('innerHTML')))
.filter(Boolean)
.join(', ')
))
Ai
p
Ai
p