New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add .env File #105
Add .env File #105
Changes from 3 commits
3f3f9dd
db3ea68
49f2371
619581b
5495bf9
eb36bcd
8e37d2d
423dbb1
752b3b4
15da30a
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
NODE_ENV=development | ||
PORT=8080 | ||
NODEMAILER_USERNAME= | ||
NODEMAILER_PASSWORD= |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
const dotenv = require('dotenv'); | ||
|
||
dotenv.config(); | ||
|
||
module.exports = { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I wonder about this vs. just letting people use I'd suggest we remove this and export nothing from There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. ok, do you want me to add
at the very beginning of index.js for now ? |
||
port: process.env.PORT, | ||
env: process.env.NODE_ENV, | ||
user: process.env.NODEMAILER_USERNAME, | ||
pass: process.env.NODEMAILER_PASSWORD, | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Above each line, please add a comment
This example file can serve as both a template, and documentation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.