replaceAsync

The replace() method of the CSSStyleSheet interface asynchronously replaces the content of the stylesheet with the content passed into it.

MDN Reference