Running Node JS server on localhost
问题 I want to make a very simple web server like this for example. const http = require('http'); http.createServer(function (req, res) { res.writeHead(200, { 'Content-Type': 'text/plain' }); res.write("Hello!"); res.end(); }).listen(8080); I put this code in WebStorm and ran it. Then I put in the same directory index.html file. <body> <button id="btn">Click Me</button> <script src="https://code.jquery.com/jquery-3.2.1.js"></script> <script src="requester.js"></script> </body> I also put requester