Hi everyone.
This is my first Next.js project, in fact, my first project on my own without using a full-stack template. I'm trying to understand how the process works:
In a full-stack app, we need environment variables to connect to the database. Since these variables are obviously sensitive, .gitignore makes sure .env is not pushed to the remote public repo.
If you're on Vercel, Vercel takes that very same remote git repo and deploys it. But since the required environment variables haven't been pushed, there's an option to include them in the dashboard.
How do you reference those variables then, with an OR statement - look in the .env file ELSE look in the Vercel dashboard? What does that OR statement look like? If they're in your local .env file, fine, but Vercel won't have that .env file, so will it by default look for those variables in what you've entered in the admin panel? How does the process work exactly?
Any help would be appreciated.
Thanks in advance!