2019-07-29 14:12:34 by沖沖html
在IDEA的 file -> setting -> Plugins,右邊手動輸入「node.js」搜索,而後點擊下載,安裝完成後要求重啓。node
解決方案參考 https://jingyan.baidu.com/article/fb48e8bef2bcb66e622e14d2.html測試
① 前往Intellij安裝包的lib文件夾下,找到漢化文件(resources_cn.jar),用壓縮軟件打開(不用解壓縮)。網站
② 將其messages文件夾內的 IdeBundle.properties(系統設置(setting)外觀選項加載不出來)、VcsBundle.properties(系統設置(setting)打不開)、UIBundle.properties(定位按鈕找不到) 這三個配置文件刪除就能夠解決對應問題。ui
③ 刪除後關閉,確保jar文件還在lib目錄下,啓動Intellij IDEA。atom
① 點擊新建項目,提供node的2個選項: Node.js 基礎模板 和 Node.js Express App 網站spa
② 建立server.js文件.net
var http = require("http"); http.createServer(function(request, response) { response.writeHead(200, {"Content-Type": "text/plain"}); response.write("Hello World"); response.end(); }).listen(8888); console.log("nodejs start listen 8888 port!");
③ 完成 Run/Debug 配置插件
解決參考 https://blog.csdn.net/atomjob/article/details/89462096code
① 前往Intellij安裝包的lib文件夾下,找到漢化文件(resources_cn.jar),用壓縮軟件打開(不用解壓縮)。
② 將其messages文件夾內的 ExecutionBundle.properties 刪除。
③ 刪除後關閉,確保jar文件還在lib目錄下,啓動Intellij IDEA。
填寫須要運行的JS文件
控制檯輸出 node js start listen 8888 port! ,則成功。
打開頁面 http://127.0.0.1:8888 或者 localhost:8888 能夠看到結果。
參考:https://www.cnblogs.com/duhuo/p/4217083.html