How can I automatically compress and minimize JavaScript files in an ASP.NET MVC app?

后端 未结 8 2115
悲&欢浪女
悲&欢浪女 2020-12-22 19:10

So I have an ASP.NET MVC app that references a number of javascript files in various places (in the site master and additional references in several views as well).

<
8条回答
  •  情歌与酒
    2020-12-22 19:48

    I have written something to handle this for me automatically. It uses google's closure compiler. You can read the code here:

    http://www.picnet.com.au/blogs/Guido/post/2009/12/10/Javascript-runtime-compilation-using-AspNet-and-Googles-Closure-Compiler.aspx

    Thanks

    Guido

提交回复
热议问题