duncansmart/LessCoffee

Coffee inside a bundle not compiling

Closed this issue · 5 comments

I'm trying to add a .coffee to a bundle on my MVC 4 project and it seems that the processor is not working in that case... (I can see the uncompiled .coffee script)

bundles.Add(new ScriptBundle("~/bundles/my-site").Include(
    "~/Scripts/core/my-site.js",
    "~/Scripts/coffee/Ads.coffee"));

The only answer I found was to disable optimization or load the coffee directly.
Is there any workaround?

I'm not sure if this is the right channel but I wonder... Why would I choose LessCoffe over BundleTransformer? Maybe I'm missing the point here.

By all means go ahead and use BundleTransformer - it seems more actively developed than LessCoffee and has a lot more features!

LessCoffee was started a few years ago, before ASP.NET Bundling came out and still suits my needs. It also uses the NodeJS as it's JavaScript engine which may be seen as an advantage from a compatibility point of view (LessJS and CofeeScript are built and tested against NodeJS).

I'm testing now... it seems that BundleTransformer is not wraping the coffee on a function like it supposed to do... I'm not sure if I really like it... :(

I'm having to use Bundle Transformer together with LessCoffee, because BT's HTTP handler for LESS is not working properly, it will only update the CSS output to the browser on App_Start. LessCoffee's HTTP handler works properly in comparison. I had been using dotless' HTTP handler for LESS previously, but it's still stuck back on LESS 1.3.1. LessCoffee is always running the latest LESS version, which is great :)