0225304 479b0dd372 fit:first 2 tygodni temu
..
.github 479b0dd372 fit:first 2 tygodni temu
test 479b0dd372 fit:first 2 tygodni temu
.eslintrc 479b0dd372 fit:first 2 tygodni temu
.nycrc 479b0dd372 fit:first 2 tygodni temu
CHANGELOG.md 479b0dd372 fit:first 2 tygodni temu
LICENSE 479b0dd372 fit:first 2 tygodni temu
README.md 479b0dd372 fit:first 2 tygodni temu
get.d.ts 479b0dd372 fit:first 2 tygodni temu
get.js 479b0dd372 fit:first 2 tygodni temu
package.json 479b0dd372 fit:first 2 tygodni temu
set.d.ts 479b0dd372 fit:first 2 tygodni temu
set.js 479b0dd372 fit:first 2 tygodni temu
tsconfig.json 479b0dd372 fit:first 2 tygodni temu

README.md

dunder-proto Version Badge

github actions coverage License Downloads

npm badge

If available, the Object.prototype.__proto__ accessor and mutator, call-bound.

Getting started

npm install --save dunder-proto

Usage/Examples

const assert = require('assert');
const getDunder = require('dunder-proto/get');
const setDunder = require('dunder-proto/set');

const obj = {};

assert.equal('toString' in obj, true);
assert.equal(getDunder(obj), Object.prototype);

setDunder(obj, null);

assert.equal('toString' in obj, false);
assert.equal(getDunder(obj), null);

Tests

Clone the repo, npm install, and run npm test