# electron-node-config **Repository Path**: molegarden/electron-node-config ## Basic Information - **Project Name**: electron-node-config - **Description**: Configuration control for electron based node applications - **Primary Language**: Unknown - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2022-01-14 - **Last Updated**: 2022-01-14 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README electron-node-config ========== Introduction ------------ This module is identical to [node-config](https://github.com/lorenwest/node-config) except that it works in the Electron environment. Whenever your app gets packaged into an Electron executable, this module will still work as expected. Even if you archive your app into app.asar, this module will still work as expected. Installation ------------ ```shell $ npm install electron-node-config $ mkdir config $ vi config/default.json ``` Usage ----- Assuming the following default.json: ```json { "Customer": { "dbConfig": { "host": "prod-db-server" }, "credit": { "initialDays": 30 } } } ``` Pull the config into your code: ```js let config = require('electron-node-config'); let dbConfig = config.get('Customer.dbConfig'); console.log(config.Customer.credit.initialDays); console.log(dbConfig.host); ``` License ------- May be freely distributed under the [MIT license](https://raw.githubusercontent.com/dw1284/electron-node-config/master/LICENSE).