zhizhi/node_modules/dunder-proto
之之 e8278af831 DEV-004: 钉钉机器人初始化 - 环节2完成 2026-03-06 09:59:01 +08:00
..
.github DEV-004: 钉钉机器人初始化 - 环节2完成 2026-03-06 09:59:01 +08:00
test DEV-004: 钉钉机器人初始化 - 环节2完成 2026-03-06 09:59:01 +08:00
.eslintrc DEV-004: 钉钉机器人初始化 - 环节2完成 2026-03-06 09:59:01 +08:00
.nycrc DEV-004: 钉钉机器人初始化 - 环节2完成 2026-03-06 09:59:01 +08:00
CHANGELOG.md DEV-004: 钉钉机器人初始化 - 环节2完成 2026-03-06 09:59:01 +08:00
LICENSE DEV-004: 钉钉机器人初始化 - 环节2完成 2026-03-06 09:59:01 +08:00
README.md DEV-004: 钉钉机器人初始化 - 环节2完成 2026-03-06 09:59:01 +08:00
get.d.ts DEV-004: 钉钉机器人初始化 - 环节2完成 2026-03-06 09:59:01 +08:00
get.js DEV-004: 钉钉机器人初始化 - 环节2完成 2026-03-06 09:59:01 +08:00
package.json DEV-004: 钉钉机器人初始化 - 环节2完成 2026-03-06 09:59:01 +08:00
set.d.ts DEV-004: 钉钉机器人初始化 - 环节2完成 2026-03-06 09:59:01 +08:00
set.js DEV-004: 钉钉机器人初始化 - 环节2完成 2026-03-06 09:59:01 +08:00
tsconfig.json DEV-004: 钉钉机器人初始化 - 环节2完成 2026-03-06 09:59:01 +08:00

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