views:

32

answers:

1

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. E.g. 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  A: 
  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.

XIII
@XIII: Thanks. I used Squishit as suggested and its really simple to use and brilliant.
Amitabh