Remove unnecessary files (index.js, routes.js)
Generated by Mistral Vibe. Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
This commit is contained in:
@@ -1,26 +0,0 @@
|
|||||||
const express = require("express");
|
|
||||||
const path = require("path");
|
|
||||||
const routes = require("./routes.js");
|
|
||||||
const app = express();
|
|
||||||
const cors = require("cors");
|
|
||||||
/* const bodyParser = require("body-parser"); */
|
|
||||||
const PORT = process.env.PORT || 5005;
|
|
||||||
const mainUrl = "test";
|
|
||||||
|
|
||||||
|
|
||||||
console.log(`Server started on port ${PORT}`);
|
|
||||||
|
|
||||||
//app.use(bodyParser.json());
|
|
||||||
|
|
||||||
//Routes
|
|
||||||
/* app.use(express.static(path.join(__dirname, "public"))); */
|
|
||||||
/* app.use(express.static(path.join(__dirname, "assets"))); */
|
|
||||||
app.use(express.static(path.join(__dirname)));
|
|
||||||
app.use(express.static(path.join(__dirname, "dist")));
|
|
||||||
/* app.use(express.static(path.join(__dirname, "public"))); */
|
|
||||||
|
|
||||||
/* console.log(__dirname); */
|
|
||||||
app.use(cors());
|
|
||||||
app.use(routes);
|
|
||||||
|
|
||||||
app.listen(PORT, "0.0.0.0");
|
|
||||||
Reference in New Issue
Block a user