ReferenceError: Can't find variable: $ when running JasmineHeadlessWebkit
问题 I've been trying to find an answer to this at least for the last two hours without any luck. I hope someone here might be able to help. I'm getting this ReferenceError: Can't find variable: $ when running my Jasmine specs using the JasmineHeadlessWebkit. The weird thing is, this only happens when I say $ -> game.init() in my game.coffee file. I can use the $ without any problems further down game.coffee . For example: window.game = init: -> $('.gamelayer').hide() $('#gamestartscreen').show()