DEV Community

Marco Filannino
Marco Filannino

Posted on

visual studio code

Hello everyone,

I'm having a serious issue with a full-stack project on my MacBook Air (Apple Silicon chip, M1/M2). The project uses Vite + Tailwind CSS for the frontend, and Node.js + Express + pg-promise for the backend. The database is PostgreSQL, running locally. I'm also using bcryptjs for password handling.

The issue is twofold:

The startup is extremely slow.

The APIs seem to work, but in reality, nothing is being written to the database.

When I run npm run dev to start Vite, or even just node server.js to start the backend, the terminal takes 5 to 6 minutes before anything happens. There are no errors, but the startup is abnormally slow.

I’ve tried opening the project both in the built-in terminal of Visual Studio Code and the system terminal, but the result is the same: it takes forever. I’ve also disabled all extensions and checked file permissions. I'm using ESModules (import/export) and "type": "module" is set in the package.json.

What could be causing such a slow startup, even for simple projects? And why does the DB connection seem to work, but doesn’t actually write anything?

I’d really appreciate any help. If needed, I can paste the contents of server.js, controllers.js, and initDb.js here.

Thanks in advance!

Top comments (0)