config/index.js
/**
 * @brief This function sets up the application configuration based on the
 *        current process environment.
 *
 * @return object configuration object.
 */
@brief This function sets up the application configuration based on the
current process environment.

@return object configuration object.
@brief This function sets up the application configuration based on the current process environment . @return object configuration object .
function initialize() {
    'use strict';
    const dotenv = require('dotenv');
    const env = process.env.NODE_ENV || "development";
    dotenv.config("../.env");
    const dev = require('./development');
    const prod = require('./production');
    if (env === "development") {
        return dev;
    }
    return prod;
}
function initialize ( ) { 'use strict' ; const dotenv = require ( 'dotenv' ) ; const env = process . env . NODE_ENV || "development" ; dotenv . config ( "../.env" ) ; const dev = require ( './development' ) ; const prod = require ( './production' ) ; if ( env === "development" ) { return dev ; } return prod ; }
@brief This function sets up the application configuration based on the
        current process environment.
@brief This function sets up the application configuration based on the current process environment .
// Return the appropriate config based on the current Node.js environment. // Load the process environment with values from the .env file. // Get the development and production configs.