I have two files: first one is a plain jQuery, and a second one is a Coffeescript
jQuery file:
$(document).ready(function(){
checkPrice();
});
CoffeeScript file:
$ ->
checkPrice = ->
alert("OK");
I get following error: "Unhandled Error: Undefined variable: checkPrice"
In the template they are included in opposite direction: coffeescript file, then jquery file.
Is there some way to make them working together ?