The htmx.config.includeIndicatorCSS option controls whether htmx adds built-in loading indicator styles.
The styles hide indicatorClass content until requestClass marks it as active.
Default: true
Syntax
Disable built-in styles when providing your own:
<meta name="htmx-config" content="includeIndicatorCSS:false">
Advanced: Accessing the Stylesheet at Runtime
When includeIndicatorCSS is true, htmx exposes the injected CSSStyleSheet as htmx.indicatorStyleSheet.
Modify the rules in place:
htmx.indicatorStyleSheet.replaceSync(` .htmx-indicator { display: none } .htmx-request .htmx-indicator, .htmx-request.htmx-indicator { display: inline } `);
Or remove it from the document entirely:
document.adoptedStyleSheets = document.adoptedStyleSheets.filter( s => s !== htmx.indicatorStyleSheet );