# fragile

> A fragile `weak` implementation for v8.

Latest version **1.3.0** (published 2018-01-01) · MIT license · 0 weekly downloads

## Install

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

## 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.3.0 |
| Published | 2018-01-01 |
| First published | 2018-01-01 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Rob Halff |
| Maintainers | rhalff |
| Keywords | memoryleak, weak, gc, v8, memory, leak, browser, node |

## Links

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

## Alternatives

- [@opentelemetry/exporter-zipkin](https://npm.io/package/@opentelemetry/exporter-zipkin.md) — 14.8M weekly downloads
- [pusher-js](https://npm.io/package/pusher-js.md) — 2.0M weekly downloads
- [browserify](https://npm.io/package/browserify.md) — 1.7M weekly downloads
- [sqs-consumer](https://npm.io/package/sqs-consumer.md) — 1.7M weekly downloads
- [@sanity/eventsource](https://npm.io/package/@sanity/eventsource.md) — 930.8K weekly downloads

## Recent versions

- 1.3.0 (latest) — 2018-01-01
- 1.2.0 — 2018-01-01
- 1.1.0 — 2018-01-01
- 1.0.5 — 2018-01-01
- 1.0.4 — 2018-01-01
- 1.0.3 — 2018-01-01
- 1.0.2 — 2018-01-01
- 1.0.1 — 2018-01-01
- 1.0.0 — 2018-01-01

## README

# Fragile

This is a fragile [weak](https://github.com/TooTallNate/node-weak) implementation which can be used in node.js and v8 based browsers.

In able to run this code you should use the v8 `expose-gc` and `allow-natives-syntax` flags.

**Chrom(e|ium):**
```
chromium-browser --js-flags="--expose-gc --allow-natives-syntax"
```

**Node.js:**
```
node --expose_gc --allow_natives_syntax
```

**Usage:**

*Referenced:*
```js
const fragile = require('fragile')

let myObject = {be: 'test'};

const myObjectIsLeaking = fragile(myObject)

myObjectIsLeaking() // true
```

*Dereferenced:*
```js
const fragile = require('fragile')

let myObject = {be: 'test'};

const myObjectIsLeaking = fragile(myObject)

myObject = null

myObjectIsLeaking() // false
```

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