ken_nogi/NodeJS/express/node_modules/gopd
Kenichiro NOGI 51a95c5e21 NodeJS
2025-07-10 10:12:37 +09:00
..
.github NodeJS 2025-07-10 10:12:37 +09:00
test NodeJS 2025-07-10 10:12:37 +09:00
.eslintrc NodeJS 2025-07-10 10:12:37 +09:00
CHANGELOG.md NodeJS 2025-07-10 10:12:37 +09:00
gOPD.d.ts NodeJS 2025-07-10 10:12:37 +09:00
gOPD.js NodeJS 2025-07-10 10:12:37 +09:00
index.d.ts NodeJS 2025-07-10 10:12:37 +09:00
index.js NodeJS 2025-07-10 10:12:37 +09:00
LICENSE NodeJS 2025-07-10 10:12:37 +09:00
package.json NodeJS 2025-07-10 10:12:37 +09:00
README.md NodeJS 2025-07-10 10:12:37 +09:00
tsconfig.json NodeJS 2025-07-10 10:12:37 +09:00

gopd Version Badge

github actions coverage License Downloads

npm badge

Object.getOwnPropertyDescriptor, but accounts for IE's broken implementation.

Usage

var gOPD = require('gopd');
var assert = require('assert');

if (gOPD) {
	assert.equal(typeof gOPD, 'function', 'descriptors supported');
	// use gOPD like Object.getOwnPropertyDescriptor here
} else {
	assert.ok(!gOPD, 'descriptors not supported');
}