nodejs – npm安装https,不能正常工作

C:\wamp\www\node-node-node>npm install https npm ERR! 404 404 Not Found: https npm ERR! 404 npm ERR! 404 'https' is not in the npm registry. npm ERR! 404 You should bug the author to publish it npm ERR! 404 npm ERR! 404 Note that you can also install from a npm ERR! 404 tarball, folder, or http url, or git url. npm ERR! System Windows_NT 6.2.9200 npm ERR! command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nod ejs\\node_modules\\npm\\bin\\npm-cli.js" "install" "https" npm ERR! cwd C:\wamp\www\node-node-node npm ERR! node -v v0.10.29 npm ERR! npm -v 1.4.14 npm ERR! code E404 npm ERR! npm ERR! Additional logging details can be found in: npm ERR! C:\wamp\www\node-node-node\npm-debug.log npm ERR! not ok code 0 

我得到这个,所以我在哪里用错了?

Node.JS内置了创buildhttp服务器和https服务器的模块。 您不必使用npm安装https,但可以直接开始使用它。 https在npm之前存在。

 var https = require("https"); var app = https.createServer(); //Rest of the code goes here