11 lines
228 B
JavaScript
11 lines
228 B
JavaScript
|
|
import dotenv from "dotenv";
|
||
|
|
import app from "./app.js";
|
||
|
|
|
||
|
|
// Carrega o arquivo .env
|
||
|
|
dotenv.config();
|
||
|
|
|
||
|
|
const PORT = process.env.PORT || 3000;
|
||
|
|
|
||
|
|
app.listen(PORT, () => {
|
||
|
|
console.log(`Servidor inicializado na porta ${PORT}.`)
|
||
|
|
})
|