Skip to content

lab009/app-config

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

39 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

@lab009/app-config

Configuration for universal web application

Install

npm install --save @lab009/app-config

Repository

https://github.com/lab009/app-config.git

Usage

Loads configuration files from a config folder in your project root.

  • default is always loaded if it exists
  • If you specify NODE_ENV=production then both production and default are loaded, with production taking precedence.
  • Any valid JS extension can be used for config - JS, json, etc.
    • To load another extension, register it before you require this module
import config from '@lab009/app-config'

For working in browser add AppConfigPlugin in webpack config.

import AppConfigPlugin from '@lab009/app-config/webpack'

var webpackConfig = {
  plugins: [
    new AppConfigPlugin(),
  ]
}

About

Configuration for universal web application

Resources

Stars

Watchers

Forks

Packages

No packages published