Skip to content

Latest commit

 

History

History
30 lines (23 loc) · 671 Bytes

README.md

File metadata and controls

30 lines (23 loc) · 671 Bytes

@clysema/env

npm (scoped) npm bundle size (minified)

Takes care of NODE_ENV, LOGGER_LEVEL and LOG_FILE enviroment variables.

Install

$ npm install @clysema/env

Usage

const env = require("@clysema/env");

(async () => {
  try {
    console.log(await env());
  } catch (e) {
    console.log(e);
  }
})();
// { env: 'production',
//   isTest: false,
//   isDevelopment: false,
//   logger: { level: 'info', file: '/tmp/controller.log' } }