904118851 29c4522d7e 123 8 hónapja
..
.github 29c4522d7e 123 8 hónapja
.eslintrc 29c4522d7e 123 8 hónapja
.nycrc 29c4522d7e 123 8 hónapja
CHANGELOG.md 29c4522d7e 123 8 hónapja
LICENSE 29c4522d7e 123 8 hónapja
README.md 29c4522d7e 123 8 hónapja
index.d.ts 29c4522d7e 123 8 hónapja
index.js 29c4522d7e 123 8 hónapja
package.json 29c4522d7e 123 8 hónapja
tsconfig.json 29c4522d7e 123 8 hónapja

README.md

hasown Version Badge

github actions coverage License Downloads

npm badge

A robust, ES3 compatible, "has own property" predicate.

Example

const assert = require('assert');
const hasOwn = require('hasown');

assert.equal(hasOwn({}, 'toString'), false);
assert.equal(hasOwn([], 'length'), true);
assert.equal(hasOwn({ a: 42 }, 'a'), true);

Tests

Simply clone the repo, npm install, and run npm test