Static content optimization
Each and every web project today has java script and css files. We don't care much about them until time of optimization comes or we need to make sure our site is usable on mobile devices with slow internet connection. Optimization usually involves several steps, among others is combining and minifing js and css files.
But if in your app you will always use minified versions of files it will be very hard to debug such a script. It usually uses one letter names for variables, has no spaces and formatting. Also after combining everything into one huge file, its very hard to navigate inside it.
Assets optimizier can help in solving these troubles. In debug mode it renders your scripts as separate files without any compression or minification. But when you go to release mode, it will optimize it for you.
In order to get started using it you have two options. First is old school one - download the source code, build it, add reference, configure. When you've done it spend another hour or two to find out why its not working. Other way is using Nuget. After installing it, use the following command to get assets optimizer:
After it you are able to use it. The Only thing that maybe going to be required is to change root paths to your assets. Usage for asp.net is different from asp.net mvc. This part describes how you can use it in your app: Getting started ASP.NET.
Here you can read about uage in asp.net mvc.
- Code is tested and used only on IIS 7 and .net 4 SP1.