This project has moved and is read-only. For the latest updates, please go here.
1

Closed

Trying to use BundleTransformer.Autoprefixer with SassAndScssAssetHandler

description

I'm using SassAndScssAssetHandler to be able to serve up SCSS files and have them convert upon request. This is very fast, and works great. However, I also wanted to start using the Autoprefixer, but it seems that it doesn't work with my approach of using SassAndScssAssetHandler.

Is there any future goal of integrating these two features?
Closed Oct 8, 2016 at 8:25 AM by Taritsyn

comments

Taritsyn wrote Oct 6, 2016 at 9:04 AM

Hello, Jrhynedh!

Debugging HTTP-handlers are intended for debug mode. For production you should always create bundles.

Create and register corresponding bundles, and then follow the instructions from “Running Autoprefixer with BundleTransformer / LESS in Debug mode” discussion on Stack Overflow.

jrhynedh wrote Oct 6, 2016 at 1:36 PM

Thank you Taritsyn.

The reason my I'm using <link href="style.scss" /> is because we have multiple cobranders that can access the same site with different configurations. New cobranders are added frequently, and I didn't want to bundle all possibilities up front, although it is possible, it would require a bit of work.

Linking directly to the scss file returned only 4ms longer than a pure css file. Can you please tell me if this approach has any risk in production?

Taritsyn wrote Oct 6, 2016 at 2:02 PM

Can you please tell me if this approach has any risk in production?
You give to the client many not optimized files.

I recommend you to read the “Best Practices for Speeding Up Your Web Site” article.