GitXplorerGitXplorer
r

fragile

public
1 stars
0 forks
0 issues

Commits

List of commits on branch master.
Unverified
72d0139445dac6f50d0b25354dc1f03ba5264be8

Release v1.3.0.

rrhalff committed 7 years ago
Unverified
0c5b176b6a0ba8c412d5d2344d22597780afd300

use eval to not choke bundlers

rrhalff committed 7 years ago
Unverified
70204077707e72ac1697b2cbe19cac634c294453

Release v1.2.0.

rrhalff committed 7 years ago
Unverified
36a73db265dbfeceb4333e7173527713d43f9557

use WeakSet instead of WeakMap

rrhalff committed 7 years ago
Unverified
90a9618d3903c1fe0844d4df8b9416ee95a2c2ab

Release v1.1.0.

rrhalff committed 7 years ago
Unverified
556340ad32553aa75240b428f452fa48d091e370

simplify api

rrhalff committed 7 years ago

README

The README file for this repository.

Fragile

This is a fragile 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:

const fragile = require('fragile')

let myObject = {be: 'test'};

const myObjectIsLeaking = fragile(myObject)

myObjectIsLeaking() // true

Dereferenced:

const fragile = require('fragile')

let myObject = {be: 'test'};

const myObjectIsLeaking = fragile(myObject)

myObject = null

myObjectIsLeaking() // false