modified: server/server.js
This commit is contained in:
parent
043c0a922a
commit
de67edeb4e
@ -4,7 +4,7 @@ const bodyParser = require('body-parser');
|
|||||||
const cors = require('cors');
|
const cors = require('cors');
|
||||||
const path = require('path');
|
const path = require('path');
|
||||||
const app = express();
|
const app = express();
|
||||||
const port = 8080;
|
const port = 4040;
|
||||||
|
|
||||||
app.use(bodyParser.json());
|
app.use(bodyParser.json());
|
||||||
app.use(cors());
|
app.use(cors());
|
||||||
@ -67,5 +67,5 @@ app.get('*', (req, res) => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
app.listen(port, () => {
|
app.listen(port, () => {
|
||||||
console.log(`服务器在 http://localhost:${port} 上运行`);
|
console.log(`服务器在 http://0.0.0.0:${port} 上运行`);
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user