urltomarkdown/node_modules/gopd
Lee Hanken 209908a1dc update dependencies, include additional CORS header 2024-04-22 12:47:34 +01:00
..
.github update dependencies, include additional CORS header 2024-04-22 12:47:34 +01:00
test update dependencies, include additional CORS header 2024-04-22 12:47:34 +01:00
.eslintrc update dependencies, include additional CORS header 2024-04-22 12:47:34 +01:00
CHANGELOG.md update dependencies, include additional CORS header 2024-04-22 12:47:34 +01:00
LICENSE update dependencies, include additional CORS header 2024-04-22 12:47:34 +01:00
README.md update dependencies, include additional CORS header 2024-04-22 12:47:34 +01:00
index.js update dependencies, include additional CORS header 2024-04-22 12:47:34 +01:00
package.json update dependencies, include additional CORS header 2024-04-22 12:47:34 +01:00

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