import express from 'express'; import { configDotenv } from "dotenv"; import router from './controller/serialPort.js'; const app = new express(); configDotenv(); // app.use(express.urlencoded({ extended: false })) app.use(router) async function run() { app.listen(process.env.PORT); console.log(`This app listens to http://localhost:${process.env.PORT}`) } await run()