-
-
Save jacbar/622ffe735ed609005fa6 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class CoffeeScriptCompiler : JsMinify | |
{ | |
public override void Process(BundleContext context, BundleResponse response) | |
{ | |
var csEngine = new CoffeeSharp.CoffeeScriptEngine(); | |
string result = string.Empty; | |
foreach(var file in response.Files) | |
{ | |
using (var reader = new StreamReader(file.FullName)) | |
{ | |
result += csEngine.Compile(reader.ReadToEnd()); | |
} | |
} | |
response.Content = result; | |
base.Process(context, response); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment