0225304 479b0dd372 fit:first hai 1 semana
..
.github 479b0dd372 fit:first hai 1 semana
test 479b0dd372 fit:first hai 1 semana
.eslintrc 479b0dd372 fit:first hai 1 semana
.nycrc 479b0dd372 fit:first hai 1 semana
CHANGELOG.md 479b0dd372 fit:first hai 1 semana
LICENSE 479b0dd372 fit:first hai 1 semana
README.md 479b0dd372 fit:first hai 1 semana
get.d.ts 479b0dd372 fit:first hai 1 semana
get.js 479b0dd372 fit:first hai 1 semana
package.json 479b0dd372 fit:first hai 1 semana
set.d.ts 479b0dd372 fit:first hai 1 semana
set.js 479b0dd372 fit:first hai 1 semana
tsconfig.json 479b0dd372 fit:first hai 1 semana

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