Prepped server
This commit is contained in:
@@ -1,7 +1,16 @@
|
||||
import express from "express";
|
||||
import dotenv from "dotenv";
|
||||
dotenv.config();
|
||||
import cors from "cors";
|
||||
|
||||
const app = express();
|
||||
const PORT = 3000;
|
||||
let PORT = process.env.APP_PORT;
|
||||
|
||||
app.use(
|
||||
cors({
|
||||
origin: process.env.CLIENT_URL,
|
||||
})
|
||||
);
|
||||
|
||||
app.get("/", (req, res) => {
|
||||
res.send("Hello from Express!");
|
||||
|
||||
Reference in New Issue
Block a user