Dapatkan nilai properti CSS JS

const style = getComputedStyle(element)

const backgroundColor = style.backgroundColor
console.log(backgroundColor) // rgb(0, 0, 0)

honeyCodedAsterisk