lib/asset_compiler.rb in vitrine-0.0.21 vs lib/asset_compiler.rb in vitrine-0.0.22
- old
+ new
@@ -86,11 +86,11 @@
source_body = File.read(coffee_source)
# We could have sent a header, but it's a nice idea to have the
# sourcemap header saved if we write out the compiled JS,
# whereas otherwise it would have been discarded
[
+ Vitrine.compile_coffeescript(source_body),
"//# sourceMappingURL=#{basename}.js.map",
- Vitrine.compile_coffeescript(source_body)
].join("\n")
rescue Errno::ENOENT # Missing CoffeeScript
forward_or_halt "No such JS file and could not find a .coffee replacement"
rescue Exception => e # CS syntax error or something alike
# Inject the syntax error into the browser console