# in-browser-env

> > Uses this [repo](https://github.com/alexjoverm/typescript-library-starter.git) as a base.

Latest version **1.0.0** (published 2019-11-13) · MIT license · 0 weekly downloads

## Install

```sh
npm install in-browser-env
pnpm add in-browser-env
yarn add in-browser-env
bun add in-browser-env
```

## Health

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

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2019-11-13 |
| First published | 2019-11-12 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=6.0.0 |
| Dependencies | 0 |
| Unpacked size | 7.2 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | HurricaneInteractive |
| Maintainers | adro.codes |

## Links

- npm: https://www.npmjs.com/package/in-browser-env
- Repository: https://github.com/HurricaneInteractive/in-browser-env
- Homepage: https://github.com/HurricaneInteractive/in-browser-env#readme
- Issues: https://github.com/HurricaneInteractive/in-browser-env/issues
- npm.io page: https://npm.io/package/in-browser-env

## Recent versions

- 1.0.0 (latest) — 2019-11-13
- 0.0.0-development — 2019-11-12

## README

# inBrowserEnv

> Uses this [repo](https://github.com/alexjoverm/typescript-library-starter.git) as a base.

inBrowserEnv is a way to check if a process is running in node or in the browser. This is useful when using frameworks like Nextjs or GatsbyJS.

## Usage

### Install

```bash
npm i in-browser-env --save
yarn add in-browser-env
```

### In Code

```js
import inBrowserEnv from "in-browser-env"

if (isBrowserEnv()) {
  // in a browser environment
}
```

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