SquishIt
SquishIt copied to clipboard
SquishIt can't minify e5-shim
Getting a javascript error: Unexpected token ,
Steps to repo:
- Create a new mvc app
- Install Squishit 0.9.8
- Add https://github.com/es-shims/es5-shim/blob/v4.1.6/es5-shim.min.js to your scripts folder
- Add the following bundle:
@(Bundle.JavaScript()
.Add("~/Scripts/jquery-1.10.2.min.js")
.Add("~/Scripts/es5-shim.min.js").ForceRelease().MvcRender("~/Scripts/main.js"))
- Run it and you should get the error
This is unlikely to be a SquishIt problem, try using the YUI minifier.
I usually configure this globally in Application_Start
Bundle.ConfigureDefaults()
.UseYuiForCssMinification()
.UseYuiForJsMinification()
@AlexCuse I think it is a SquishIt issue because the version of ajaxmin is capped (AjaxMin (≥ 4.48.4489.28432 && ≤ 4.97.4951.28483) - so out of the box the maximum version of the minifier that is specified does not work.
That is because there are breaking changes in ajaxmin past that version. I plan to update in v1.0. f you want to use a newer version in the meantime you can implement your own minifiers but I would suggest using YUI (this is going to be the default in 1.0)