问题:
我从 macintosh 终端执行以下命令:
I execute the following command from the macintosh terminal:
我从终端收到以下输出错误:
I recieve the following output error from the terminal:
-bash: jsx: command not found相关信息:
- 我正在学习以下教程:facebook.github.io/react/docs/getting-started.html
我从教程中执行了以下命令,输出为正:
- I am following the following tutorial: facebook.github.io/react/docs/getting-started.html
I executed the following command from the tutorial with positive output:
这条指令紧跟在产生错误的指令之前:
This instruction immediately precedes the instruction that produces the error:
环境信息:
$ node -v v0.12.4 $ npm 2.10.1谷歌精选:
- groups.google/forum/#!topic/reactjs/TUBkgptg2dM
附加说明:
Best of google 很短,因为提供教程所提供信息的链接并不多.这样做的结果是,我认为有一个明显的解决方案,而我只是愚蠢.
Best of google is short because there aren't many links that provide information that the tutorial provides. A result of this is that I think there is an obvious solution and that I am just being dumb.
如果需要,我会提供更多信息
I will provide more information if requested
解决方案我的独特问题:
执行以下命令:
Execute the following command:
原问题命令:
Original problem command:
$ jsx --watch src/ build/新的正输出:
New positive output:
built Module("helloworld") ["helloworld"]运行:
npm config get prefix这将为您提供有关全局 npm 模块安装位置的线索.您需要将上述返回的目录下的bin目录添加到您的路径中.例如,它可能会返回/usr/local,在这种情况下,您应该将/usr/local/bin 添加到您的 PATH 中.你可以这样做:
that will give you a clue as to where your global npm modules are installed. you need to add the bin directory under the directory returned by the above to your path. for example, it might return /usr/local, in which case you should add /usr/local/bin to your PATH. You could just do:
export PATH=$PATH:$(npm config get prefix)/bin更多推荐
在 mac 终端上找不到 jsx 命令
发布评论