Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript get css property

const style = getComputedStyle(element)

const backgroundColor = style.backgroundColor
console.log(backgroundColor) // rgb(0, 0, 0)
Source by zellwk.com #
 
PREVIOUS NEXT
Tagged: #javascript #css #property
ADD COMMENT
Topic
Name
5+5 =