简体   繁体   中英

Using MS Ajax Minfier 4.0 for Asp.Net MVC 2.0?

I am planning to use MS Ajax Minifier with Asp.Net MVC 2.0 for handling the Js and Css files. Does anyone has experience with MS Ajax Minifier? I have following questions regarding this.

  1. Is it the best way to use JS/CSS files in Asp.Net MVC or is there a better way. Eg YUI Compressor, Telerik Extension for MVC ?
  2. As I understand we can use this to convert SomeFile.js to SomeFile.min.js at the build time. However In my mvc Views I still have the Script reference pointing to SomeFile.js . How does the browser will pick the SomeFile.min.js file?
  1. It's one possibility to use. The integration when building is a nice asset and it has hypercrunching.
  2. You must use the SomeFile.min.js in your script reference. But in Visual Studio you can have an uncompressed file with this name SomeFile-vsdoc.js for intellisense coding (in which you can also use xml comments which will be picked up by VS.

Another approach would be to use SquishIt .

Grz, Kris.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM