Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

assign multiple styles via js

const anchor = document.querySelector('a');

Object.assign(anchor.style, {
    color: 'white',
    letterSpacing: '2px'
});
Source by umaar.com #
 
PREVIOUS NEXT
Tagged: #assign #multiple #styles #js
ADD COMMENT
Topic
Name
3+2 =