Have ideas to improve npm?Join in the discussion! »

    divulge

    2.0.2 • Public • Published

    divulge

    TRAVIS NPM

    js-standard-style

    This module provides a function to override default configuration [recursively] with their equivalent non-delimited uppercase names, assuming they exist in the environment.

    Example

    var divulge = require('divulge')
    var config = divulge({
      port: 8000,
      secret: {
        user: "",
        pass: ""
      }
    }, '', process.env)
     
    // ...
     
    console.log(config.port, config.secret.user, config.secret.pass)

    When executed with PORT=5000 SECRETUSER='foo' SECRETPASS='bar' in the environment, the above program will print 5000 foo bar to the console.

    License

    This library is free and open-source software released under the MIT license.

    Install

    npm i divulge

    DownloadsWeekly Downloads

    0

    Version

    2.0.2

    License

    MIT

    Last publish

    Collaborators

    • avatar