How To Read Environmental Variables From .env File In Firebase?
The easiest, multiplaform way to store environmental variables is by using .env file in the root of our project. Now, the problem I'm facing is related to Firebase, more precisely
Solution 1:
The Firebase CLI deploys everything in the functions folder at the time of deployment, except for node_modules. If it's not in there for deployment, you won't be able to read it at all without somehow going off-host to a remote network location. There is currently no way to make the CLI merge in files from other locations. You could perhaps try a symlink.
unless the .env was manually copied to the deployable functions folder.
This is probably what you'll have to end up doing.
Baca Juga
- Node.js & Mysql - Error: 1251 - Client Does Not Support Authentication Protocol Requested By Server; Consider Upgrading Mysql Client
- Socket.io Connection Keep Increasing Each Time A New Connect Has Been Made
- Is My Function Not Resolving Correctly? Also It Won't Write To Firebase To The Databse. No Errors
Post a Comment for "How To Read Environmental Variables From .env File In Firebase?"