Skip to content

Latest commit

 

History

History
27 lines (20 loc) · 519 Bytes

File metadata and controls

27 lines (20 loc) · 519 Bytes

@qiwi/uniconfig-plugin-dotenv

Uniconfig dotenv parser plugin

Install

  npm i @qiwi/uniconfig-plugin-dotenv
  yarn add @qiwi/uniconfig-plugin-dotenv

Usage

Imagine ./some.env

FOO=BAR
BAZ=QUX
import Config, {rollupPlugin} from '@qiwi/uniconfig-core'
import uniconfigPluginDotenv from '@qiwi/uniconfig-plugin-dotenv'
    
rollupPlugin(uniconfigPluginDotenv)
const config = new Config('./some.env', {mode: SYNC, pipeline: 'file>dotenv'})

config.get('FOO') // 'BAR'