We are using Sitecore 9.3 along with SXA and have 3 instances(1CM and 2CDs). I am facing issue related to SXA asset optimization. Our project globally inherits "Concatenate and Minify option" to optimize CSS files. But the generated optimized-min.css file does not load properly and throws an internal error when tried to navigate directly from browser. When we disable it, CSS works fine.

I see a warning in chrome developer tool - "Resource interpreted as Stylesheet but transferred with MIME type text/html" for the generated CSS file. Can someone kindly guide me is this warning related to this issue or something else is causing styles to break in our website? We would like to minify CSS files for our website. So could anyone please help me on this? Any idea or thoughts would be appreciated.

  • Looks like your css has something that is not recognized as css syntax and is breaking your file, giving the error. Try to delete file by file, or code block by code block until it stops giving the error to find where the typo is. – Jorge Pimenta Mar 15 at 21:48
  • Thank you for the reply @JorgePimenta. I see all css files have proper syntax and I noticed this issue happens only in CD servers, but not in CM server. CM site works without any errors. Any thoughts on this please. – user5955 Apr 8 at 19:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.