Node.JS NPM 不适用于 Windows [英] Node.JS NPM not working on Windows

查看:53
本文介绍了Node.JS NPM 不适用于 Windows的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚刚安装了最新版本的 nodejs,虽然我可以让它很好地运行 js 文件,但我无法让 npm 做任何事情.

I just installed the latest version of nodejs, and while I can get it to run js files just fine, I can't get npm to do anything.

如果我打开 node.exe,它会出现一个提示,然后我分别尝试了以下每一个,但没有一个工作:

If I open the node.exe, it brings up a prompt, then I separately tried each of the following and none of them work:

> node npm install socket.io
> npm install socket.io
> help
> node help

以上所有结果都只返回..."行,然后我输入的每件事之后,我都会得到另一行...".

ALL of the above result in nothing but the line "..." to be returned, then every thing I type in after that, I just get another line of "...".

这非常令人沮丧.我做错了什么?

This is extremely frustrating. What am I doing wrong?

推荐答案

打开 node.exe 将打开读取-评估-打印循环 (REPL).试试吧:

Opening node.exe will bring up the Read–eval–print loop (REPL). Try just:

c:\users\windowslogin>npm install socket.io

这篇关于Node.JS NPM 不适用于 Windows的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆