monquigrid/node_modules/dunder-proto
2025-07-16 23:56:37 +00:00
..
.github Welcome to the AI slop. 2025-07-16 23:56:37 +00:00
test Welcome to the AI slop. 2025-07-16 23:56:37 +00:00
.eslintrc Welcome to the AI slop. 2025-07-16 23:56:37 +00:00
.nycrc Welcome to the AI slop. 2025-07-16 23:56:37 +00:00
CHANGELOG.md Welcome to the AI slop. 2025-07-16 23:56:37 +00:00
get.d.ts Welcome to the AI slop. 2025-07-16 23:56:37 +00:00
get.js Welcome to the AI slop. 2025-07-16 23:56:37 +00:00
LICENSE Welcome to the AI slop. 2025-07-16 23:56:37 +00:00
package.json Welcome to the AI slop. 2025-07-16 23:56:37 +00:00
README.md Welcome to the AI slop. 2025-07-16 23:56:37 +00:00
set.d.ts Welcome to the AI slop. 2025-07-16 23:56:37 +00:00
set.js Welcome to the AI slop. 2025-07-16 23:56:37 +00:00
tsconfig.json Welcome to the AI slop. 2025-07-16 23:56:37 +00:00

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