Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to run coffeescript with web storm

I'm having trouble running a coffeescript configuration with webstorm. If I enable the coffeescript plugin in the run configuration I get the following error

/usr/bin/coffee app.coffee
env: node: No such file or directory

I tried the solution in the support forums of adding my path variable to the environment variables but still no fix.

enter image description here

like image 853
MonkeyBonkey Avatar asked Oct 09 '12 12:10

MonkeyBonkey


People also ask

How do I use CoffeeScript in HTML?

If you are looking to implement coffee script in html, take a look at this. You simple need to add a <script type="text/coffeescript" src="app. coffee"></script> to execute coffee script code in an HTML file.

Does CoffeeScript compile to JavaScript?

CoffeeScript. CoffeeScript is a little language that compiles into JavaScript.

Why should you use CoffeeScript instead of JavaScript?

CoffeeScript is something that makes even good JavaScript code better. CoffeeScript compiled code can do everything that natively written JavaScript code can, only the code produced by using CoffeeScript is way shorter, and much easier to read.


1 Answers

Because, the executable file is not found yet.

Goto Terminal and type: echo NODE_PATH or echo $NODE_PATH to see where is the file.

On windows, C:\Users[YOUR_USER_NAME]\AppData\Roaming\npm\node_modules\coffee-script\bin\coffee

So, use Spotlight search tool to have a look at /usr/local/npm ..... or somewhere else.

like image 132
CodeFarmer Avatar answered Oct 02 '22 12:10

CodeFarmer