# envitro

> Load environment from package.json.

Latest version **1.0.3** (published 2016-07-15) · MIT license · 0 weekly downloads

## Install

```sh
npm install envitro
pnpm add envitro
yarn add envitro
bun add envitro
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.3 |
| Published | 2016-07-15 |
| First published | 2016-04-08 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Maintainers | weo-edu |

## Links

- npm: https://www.npmjs.com/package/envitro
- Repository: https://github.com/joshrtay/envitro
- Homepage: https://github.com/joshrtay/envitro#readme
- Issues: https://github.com/joshrtay/envitro/issues
- npm.io page: https://npm.io/package/envitro

## Dependencies (2)

- [@f/foreach](https://npm.io/package/@f/foreach.md) ^1.2.2
- [@f/is-string](https://npm.io/package/@f/is-string.md) ^1.1.1

## Recent versions

- 1.0.3 (latest) — 2016-07-15
- 1.0.2 — 2016-05-28
- 1.0.1 — 2016-04-21
- 1.0.0 — 2016-04-08

## README

# envitro

[![Build status][travis-image]][travis-url]
[![Git tag][git-image]][git-url]
[![NPM version][npm-image]][npm-url]
[![Code style][standard-image]][standard-url]

Load environment from package.json.

I'm pretty sure this is the best name ever.

## Installation

    $ npm install envitro

## Usage

package.json
```js
{
    "environment": {
      "production": {
        "API": "api.weo.io"
      },
      "development": {
        "API": "localhost:3000"
      }
    }
}
```

NODE_ENV="development"
```js
require('envitro')()

process.env.API // => 'localhost:3000'
```

## API

### envitro(dir)

- `dir` - director to locate package.json (default: process.cwd)

## License

MIT

[travis-image]: https://img.shields.io/travis/joshrtay/envitro.svg?style=flat-square
[travis-url]: https://travis-ci.org/joshrtay/envitro
[git-image]: https://img.shields.io/github/tag/joshrtay/envitro.svg?style=flat-square
[git-url]: https://github.com/joshrtay/envitro
[standard-image]: https://img.shields.io/badge/code%20style-standard-brightgreen.svg?style=flat-square
[standard-url]: https://github.com/feross/standard
[npm-image]: https://img.shields.io/npm/v/envitro.svg?style=flat-square
[npm-url]: https://npmjs.org/package/envitro

---
_Source: https://npm.io/package/envitro · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
