max_liu b7ab7c8514 chore: 更新node_modules依赖文件 пре 2 недеља
..
.github b7ab7c8514 chore: 更新node_modules依赖文件 пре 2 недеља
test b7ab7c8514 chore: 更新node_modules依赖文件 пре 2 недеља
.eslintrc b7ab7c8514 chore: 更新node_modules依赖文件 пре 2 недеља
CHANGELOG.md b7ab7c8514 chore: 更新node_modules依赖文件 пре 2 недеља
LICENSE b7ab7c8514 chore: 更新node_modules依赖文件 пре 2 недеља
README.md b7ab7c8514 chore: 更新node_modules依赖文件 пре 2 недеља
gOPD.d.ts b7ab7c8514 chore: 更新node_modules依赖文件 пре 2 недеља
gOPD.js b7ab7c8514 chore: 更新node_modules依赖文件 пре 2 недеља
index.d.ts b7ab7c8514 chore: 更新node_modules依赖文件 пре 2 недеља
index.js b7ab7c8514 chore: 更新node_modules依赖文件 пре 2 недеља
package.json b7ab7c8514 chore: 更新node_modules依赖文件 пре 2 недеља
tsconfig.json b7ab7c8514 chore: 更新node_modules依赖文件 пре 2 недеља

README.md

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');
}