1.0.0 • Published 6 years ago

environmentjs v1.0.0

Weekly downloads
4
License
ISC
Repository
github
Last release
6 years ago

Environment JS

Installation

  1. run this command
$ npm i environmentjs
  1. and copy env.js to your directory where node_modules folder located

env.js

export default {
  "env": "local",
  "local": {
    test_var: "This is Variable for Local Environment"
  },
  "dev": {
    test_var: "This is Variable for Development Environment"
  },
  "prod": {
    test_var: "This is Variable for Production Environment"
  }
}

Usage

import env from 'environmentjs';
console.log(env.test_var)

Output

This is Variable for Local Environment