where is env config file for nodejs on mac code example

Example 1: dotenv not loading process.env in node

Rename your file to just .env, removing any prefix
require it as early as possible in your application with the code snippet below
require('dotenv').config();

Example 2: set a variable in express.js

app.set('oneSetting', 'one');
app.set('twoSetting', 'two');
app.set('view engine','jade');

console.log(app.settings.oneSetting);
console.log(app.settings.twoSetting);
console.log(app.settings['view engine']);