MCPcopy
hub / github.com/jsdom/jsdom / has

Function has

lib/jsdom/living/window-properties.js:189–201  ·  view source on GitHub ↗
(target, property)

Source from the content-addressed store, hash-verified

187 return Reflect.getOwnPropertyDescriptor(target, property);
188 },
189 has(target, property) {
190 if (typeof property === "symbol") {
191 return Reflect.has(target, property);
192 }
193
194 const desc = this.getOwnPropertyDescriptor(target, property);
195 if (desc !== undefined) {
196 return true;
197 }
198
199 const parent = Object.getPrototypeOf(target);
200 return Reflect.has(parent, property);
201 },
202 get(target, property, receiver) {
203 if (typeof property === "symbol") {
204 return Reflect.get(target, property, receiver);

Callers

nothing calls this directly

Calls 1

hasMethod · 0.45

Tested by

no test coverage detected