I found that CssRewriteUrlTransform fails to run if you're referencing a *.css
file and you have the associated *.min.css
file in the same folder.
To fix this, either delete the *.min.css
file or reference it directly in your bundle:
bundles.Add(new Bundle("~/bundles/bootstrap")
.Include("~/Libs/bootstrap3/css/bootstrap.min.css", new CssRewriteUrlTransform()));
After that you do that, your URLs will be transformed correctly and your images should be correctly resolved.