← Back to context

Comment by gavinray

7 months ago

I don't actually understand what this VS Code extension provides?

  > Behind the scenes, this extension is using a Docker-based local proxy (via Neon Local) to route traffic from localhost to your Neon database branch. The extension handles authentication, networking, and branch selection for you. All you have to do is select which branch you want to connect to and run your application.

  > The extension launches a local Docker container that exposes a static Postgres connection at localhost:5432. Your app connects using a fixed connection string: postgres://neon:npg@localhost:5432

And then you're meant to read this connection string from an ENV var

This seems like an obscenely complex way to essentially set an ENV var pointing at a given database.

I can either install a VS Code extension, and enter my Neon info in it's UI to set this ENV var, or...

I can change the PG_URL in my .env file to the same info I would have entered in the extension UI, right?

Am I missing something?