I have a CSS with a variable set in it. I know how to change the value for the variable using plain Javascript. I need to do the same using jQuery.
This is the code I have...
<style>
:root{
--board-bg-color:#7DD0D6;
}
<style>
To change the value of "--board-bg-color" in plain Javascript, I can use
document.body.style.setProperty("--board-bg-color", "#"+Color);
I need to know if there is an equivalent in jQuery.
I have tried using the css function for body and document, but it doesn't work
jQuery("body").css("--board-bg-color","#"+Color);