# bugsnag-browser-lite

> Bugsnag error reporting on the browser

Latest version **2.0.3** (published 2020-04-13) · MIT license · 0 weekly downloads

## Install

```sh
npm install bugsnag-browser-lite
pnpm add bugsnag-browser-lite
yarn add bugsnag-browser-lite
bun add bugsnag-browser-lite
```

## 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 | 2.0.3 |
| Published | 2020-04-13 |
| First published | 2020-04-10 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 3 |
| Unpacked size | 112.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 2 |
| Author | Mukesh Soni |
| Maintainers | mukeshsoni |
| Keywords | bugsnag, browser, logger, lite, light |

## Links

- npm: https://www.npmjs.com/package/bugsnag-browser-lite
- Repository: https://github.com/mukeshsoni/bugsnag-browser-lite
- Homepage: https://github.com/mukeshsoni/bugsnag-browser-lite#readme
- Issues: https://github.com/mukeshsoni/bugsnag-browser-lite/issues
- npm.io page: https://npm.io/package/bugsnag-browser-lite

## Dependencies (3)

- [error-stack-parser](https://npm.io/package/error-stack-parser.md) ^2.0.6
- [safe-json-stringify](https://npm.io/package/safe-json-stringify.md) ^1.2.0
- [@types/safe-json-stringify](https://npm.io/package/@types/safe-json-stringify.md) ^1.1.0

## Alternatives

- [@oh-my-pi/pi-natives](https://npm.io/package/@oh-my-pi/pi-natives.md) — 51.8K weekly downloads
- [@capgo/capacitor-light-sensor](https://npm.io/package/@capgo/capacitor-light-sensor.md) — 3.0K weekly downloads
- [@heyhuynhgiabuu/pi-diff](https://npm.io/package/@heyhuynhgiabuu/pi-diff.md) — 492 weekly downloads
- [@lotsa/verdant-lang-asm](https://npm.io/package/@lotsa/verdant-lang-asm.md) — 38 weekly downloads
- [new-era-syntax](https://npm.io/package/new-era-syntax.md) — 20 weekly downloads

## Recent versions

- 2.0.3 (latest) — 2020-04-13
- 2.0.2 — 2020-04-13
- 2.0.1 — 2020-04-13
- 2.0.0 — 2020-04-12
- 1.1.1 — 2020-04-11
- 1.1.0 — 2020-04-11
- 1.0.4 — 2020-04-11
- 1.0.3 — 2020-04-11
- 1.0.2 — 2020-04-10
- 1.0.1 — 2020-04-10
- 1.0.0 — 2020-04-10

## README

bugsnag-browser-lite is a light weight replacement for [@bugsnag/js](https://github.com/bugsnag/bugsnag-js). 

`@bugsnag/js` does a lot of stuff and works in both browser and nodejs. This
makes the library very large. I made `bugsnag-browser-lite` which can be used
only in the browser and is significantly smaller than `@bugsnag/js`. 

This library does not yet have auto notification on unhandled errors and exceptions.

### Installation

```
npm install bugsnag-browser-lite -save-dev
```

### Usage
```
import bugsnag from 'bugsnag-browser-lite';

const bugsnagClient = bugsnag('your-bugsnag-api-key')

// on error, call notify
bugsnagClient.notify(error, { metaData: additionalInformation });
```

Catching and logging all unhandled exceptions in react.

```
import bugsnag, { ErrorBoundary } from 'bugsnag-browser-lite';

const bugsnagClient = bugsnag('your-bugsnag-api-key')

<ErrorBoundary bugsnagClient={bugsnagClient}> >
  <YourApp />
</ErrorBoundary>
```

It's written in typescript and the types are published with the package.

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