1

我已经用 Ajaxmin 4.96.4941 安装了 squishit 版本 0.9.8.2。问题是当我运行 ASP.net 站点时出现错误

[FileLoadException: Could not load file or assembly 'AjaxMin, Version=4.48.4489.28432, Culture=neutral, PublicKeyToken=21ef50ce11b5d80f' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)]

SquishIt.Framework.Minifiers.JavaScript.MsMinifier.Minify(字符串内容)在 c:\dev\urandom\SquishIt\SquishIt.Framework\Minifiers\JavaScript\MsMinifier.cs:31 SquishIt.Framework.Base.BundleBase 1.MinifyIfNeeded(String content, Boolean minify) in c:\dev\urandom\SquishIt\SquishIt.Framework\Base\BundleBase.Rendering.Internals.cs:340 System.Linq.WhereSelectArrayIterator2.MoveNext() +110 System.Linq.d__16 2.MoveNext() +348 System.Collections.Generic.List1..ctor(IEnumerable 1 collection) +476 System.Linq.Enumerable.ToList(IEnumerable1 source) +69 SquishIt.Framework.JavaScript.JavaScriptBundle.AggregateContent(List 1 assets, StringBuilder sb, String outputFile) in c:\dev\urandom\SquishIt\SquishIt.Framework\JavaScript\JavaScriptBundle.cs:84 SquishIt.Framework.Base.BundleBase1.GetMinifiedContent(List 1 assets, String outputFile) in c:\dev\urandom\SquishIt\SquishIt.Framework\Base\BundleBase.Rendering.Internals.cs:333 SquishIt.Framework.Base.BundleBase1.RenderRelease(String key, String renderTo, IRenderer renderer) in c: \dev\urandom\SquishIt\SquishIt.Framework\Base\BundleBase.Rendering.Internals.cs:290

4

1 回答 1

0

我认为 4.96 在某些时候存在问题,但不记得具体是什么。您是否尝试过添加绑定重定向?

我建议更新到 4.97.4951.28483(或使用 YUI 缩小器)。

对于后者,在 global.asax.cs 的某个地方(在你做任何包渲染之前)

Bundle.ConfigureDefaults().UseYuiForJsMinification()

于 2016-04-26T17:51:04.523 回答