Answers for "how to use multiple css using js"

CSS
3

how to add multiple css style in javascript

document.getElementById("myElement").style.cssText = "display: block; position: absolute";

//use template literals
document.getElementById("myElement").style.cssText = `
  display: block; 
  position: absolute;
`;
Posted by: Guest on December-27-2021
1

setting multiple css using dom

document.getElementById("myElement").style.cssText = "display: block; position: absolute";
Posted by: Guest on November-07-2020

Code answers related to "how to use multiple css using js"

Browse Popular Code Answers by Language