gpt4 book ai didi

node.js - Enide Studio 2014无法使用

转载 作者:太空宇宙 更新时间:2023-11-04 02:32:00 26 4
gpt4 key购买 nike

Enide Studio 2014 基于 Eclipse 4.4 M4 Luna 预览版

新建 ->Node.js 项目。

hello-world-server.njs是这样的:

var http = require('http');
http.createServer(function handler(req, res) {
res.writeHead(200, {'Content-Type': 'text/plain'});
res.end('Hello World\n');
}).listen(1337, '127.0.0.1');
console.log('Server running at http://127.0.0.1:1337/');

1个问题:为什么 hello-world-server.njs 不是 hello-world-server.js。

JS和NJS有什么区别

2个问题:我正在运行 Node 应用程序

     Console show:
org.nodeclipse.debug.launch.LaunchShortcut
node E:\work\node_eclipse_w\k\hello-world-server.njs --tea-pot-mode

但我无法访问页面“127.0.0.1:1337”

结束:谢谢。

最佳答案

阅读更新的简介 http://www.nodeclipse.org/enide/studio/2014/

简而言之,您需要将 Enide Studio 2014 插件 (v0.17) 安装到最新的 Eclipse 中。现在您使用的是旧版Nodeclipse v0.11

您还可以将 Eclipse 和 Nodeclipse(即 Enide Studio 2014)更新到最新版本。

关于node.js - Enide Studio 2014无法使用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25903399/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com