{"_id":"object.hasown","_rev":"3337874","name":"object.hasown","description":"ES spec-compliant shim for Object.hasOwn","dist-tags":{"latest":"1.1.4"},"maintainers":[{"name":"ljharb","email":""}],"time":{"modified":"2024-07-10T08:08:07.000Z","created":"2021-05-25T19:02:20.123Z","1.1.4":"2024-03-22T20:20:02.948Z","1.1.3":"2023-08-28T16:31:12.074Z","1.1.2":"2022-11-07T07:09:27.575Z","1.1.1":"2022-05-05T16:14:23.282Z","1.1.0":"2021-10-04T04:28:25.020Z","1.0.0":"2021-05-25T19:02:20.123Z"},"users":{},"author":{"name":"Jordan Harband","email":"ljharb@gmail.com"},"repository":{"type":"git","url":"git+https://github.com/es-shims/Object.hasOwn.git"},"versions":{"1.1.4":{"name":"object.hasown","version":"1.1.4","description":"ES spec-compliant shim for Object.hasOwn","main":"index.js","exports":{".":"./index.js","./auto":"./auto.js","./polyfill":"./polyfill.js","./implementation":"./implementation.js","./shim":"./shim.js","./package.json":"./package.json"},"scripts":{"prepack":"npmignore --auto --commentLines=autogenerated","prepublish":"not-in-publish || npm run prepublishOnly","prepublishOnly":"safe-publish-latest","lint":"eslint --ext=js,mjs .","postlint":"es-shim-api --bound","pretest":"npm run lint","tests-only":"nyc tape 'test/**/*.js'","test":"npm run tests-only","posttest":"aud --production","version":"auto-changelog && git add CHANGELOG.md","postversion":"auto-changelog && git add CHANGELOG.md && git commit --no-edit --amend && git tag -f \"v$(node -e \"console.log(require('./package.json').version)\")\""},"repository":{"type":"git","url":"git+https://github.com/es-shims/Object.hasOwn.git"},"keywords":["Object","hasOwn","polyfill","shim","es-shim API"],"author":{"name":"Jordan Harband","email":"ljharb@gmail.com"},"funding":{"url":"https://github.com/sponsors/ljharb"},"license":"MIT","bugs":{"url":"https://github.com/es-shims/Object.hasOwn/issues"},"homepage":"https://github.com/es-shims/Object.hasOwn","dependencies":{"define-properties":"^1.2.1","es-abstract":"^1.23.2","es-object-atoms":"^1.0.0"},"devDependencies":{"@es-shims/api":"^2.4.2","@ljharb/eslint-config":"^21.1.0","aud":"^2.0.4","auto-changelog":"^2.4.0","call-bind":"^1.0.7","eslint":"=8.8.0","functions-have-names":"^1.2.3","has-strict-mode":"^1.0.1","has-symbols":"^1.0.3","in-publish":"^2.0.1","npmignore":"^0.3.1","nyc":"^10.3.2","safe-publish-latest":"^2.0.0","tape":"^5.7.5"},"auto-changelog":{"output":"CHANGELOG.md","template":"keepachangelog","unreleased":false,"commitLimit":false,"backfillLimit":false,"hideCredit":true},"publishConfig":{"ignore":[".github/workflows"]},"engines":{"node":">= 0.4"},"_id":"object.hasown@1.1.4","gitHead":"150c494eb2450c03c6d023b66587413b3bd20e3a","_nodeVersion":"21.7.0","_npmVersion":"10.5.0","dist":{"shasum":"e270ae377e4c120cdcb7656ce66884a6218283dc","size":6162,"noattachment":false,"key":"/object.hasown/-/object.hasown-1.1.4.tgz","tarball":"http://registry.cnpm.dingdandao.com/object.hasown/download/object.hasown-1.1.4.tgz"},"_npmUser":{"name":"ljharb","email":"ljharb@gmail.com"},"directories":{},"maintainers":[{"name":"ljharb","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/object.hasown_1.1.4_1711138802773_0.0469214087574541"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2024-03-22T20:20:02.948Z","publish_time":1711138802948,"_source_registry_name":"default","_cnpm_publish_time":1711138802948},"1.1.3":{"name":"object.hasown","version":"1.1.3","description":"ES spec-compliant shim for Object.hasOwn","main":"index.js","exports":{".":[{"import":"./index.mjs","require":"./index.js","default":"./index.js"},"./index.js"],"./auto":"./auto.js","./polyfill":"./polyfill.js","./implementation":"./implementation.js","./shim":"./shim.js","./package.json":"./package.json"},"scripts":{"prepack":"npmignore --auto --commentLines=autogenerated","prepublish":"not-in-publish || npm run prepublishOnly","prepublishOnly":"safe-publish-latest","lint":"eslint --ext=js,mjs .","postlint":"es-shim-api --bound","pretest":"npm run lint","tests-only":"nyc tape 'test/**/*.js'","tests-esm":"nyc node test/index.mjs","test":"npm run tests-only && npm run tests-esm","posttest":"aud --production","version":"auto-changelog && git add CHANGELOG.md","postversion":"auto-changelog && git add CHANGELOG.md && git commit --no-edit --amend && git tag -f \"v$(node -e \"console.log(require('./package.json').version)\")\""},"repository":{"type":"git","url":"git+https://github.com/es-shims/Object.hasOwn.git"},"keywords":["Object","hasOwn","polyfill","shim","es-shim API"],"author":{"name":"Jordan Harband","email":"ljharb@gmail.com"},"funding":{"url":"https://github.com/sponsors/ljharb"},"license":"MIT","bugs":{"url":"https://github.com/es-shims/Object.hasOwn/issues"},"homepage":"https://github.com/es-shims/Object.hasOwn","dependencies":{"define-properties":"^1.2.0","es-abstract":"^1.22.1"},"devDependencies":{"@es-shims/api":"^2.4.2","@ljharb/eslint-config":"^21.1.0","aud":"^2.0.3","auto-changelog":"^2.4.0","call-bind":"^1.0.2","eslint":"=8.8.0","functions-have-names":"^1.2.3","has-strict-mode":"^1.0.1","has-symbols":"^1.0.3","in-publish":"^2.0.1","npmignore":"^0.3.0","nyc":"^10.3.2","safe-publish-latest":"^2.0.0","tape":"^5.6.6"},"auto-changelog":{"output":"CHANGELOG.md","template":"keepachangelog","unreleased":false,"commitLimit":false,"backfillLimit":false,"hideCredit":true},"publishConfig":{"ignore":[".github/workflows"]},"_id":"object.hasown@1.1.3","gitHead":"f96023009dcbfcbe41f706d00cfd953f2bf0db3a","_nodeVersion":"20.5.1","_npmVersion":"9.8.0","dist":{"shasum":"6a5f2897bb4d3668b8e79364f98ccf971bda55ae","size":6006,"noattachment":false,"key":"/object.hasown/-/object.hasown-1.1.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/object.hasown/download/object.hasown-1.1.3.tgz"},"_npmUser":{"name":"ljharb","email":"ljharb@gmail.com"},"directories":{},"maintainers":[{"name":"ljharb","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/object.hasown_1.1.3_1693240271825_0.1885264131448623"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2023-08-28T16:31:12.074Z","publish_time":1693240272074,"_source_registry_name":"default","_cnpm_publish_time":1693240272074},"1.1.2":{"name":"object.hasown","version":"1.1.2","description":"ES spec-compliant shim for Object.hasOwn","main":"index.js","exports":{".":[{"import":"./index.mjs","require":"./index.js","default":"./index.js"},"./index.js"],"./auto":"./auto.js","./polyfill":"./polyfill.js","./implementation":"./implementation.js","./shim":"./shim.js","./package.json":"./package.json"},"scripts":{"prepack":"npmignore --auto --commentLines=autogenerated","prepublish":"not-in-publish || npm run prepublishOnly","prepublishOnly":"safe-publish-latest","lint":"eslint --ext=js,mjs .","postlint":"es-shim-api --bound","pretest":"npm run lint","tests-only":"nyc tape 'test/**/*.js'","tests-esm":"nyc node test/index.mjs","test":"npm run tests-only && npm run tests-esm","posttest":"aud --production","version":"auto-changelog && git add CHANGELOG.md","postversion":"auto-changelog && git add CHANGELOG.md && git commit --no-edit --amend && git tag -f \"v$(node -e \"console.log(require('./package.json').version)\")\""},"repository":{"type":"git","url":"git+https://github.com/es-shims/Object.hasOwn.git"},"keywords":["Object","hasOwn","polyfill","shim","es-shim API"],"author":{"name":"Jordan Harband","email":"ljharb@gmail.com"},"funding":{"url":"https://github.com/sponsors/ljharb"},"license":"MIT","bugs":{"url":"https://github.com/es-shims/Object.hasOwn/issues"},"homepage":"https://github.com/es-shims/Object.hasOwn","dependencies":{"define-properties":"^1.1.4","es-abstract":"^1.20.4"},"devDependencies":{"@es-shims/api":"^2.2.3","@ljharb/eslint-config":"^21.0.0","aud":"^2.0.1","auto-changelog":"^2.4.0","call-bind":"^1.0.2","eslint":"=8.8.0","functions-have-names":"^1.2.3","has-strict-mode":"^1.0.1","has-symbols":"^1.0.3","in-publish":"^2.0.1","npmignore":"^0.3.0","nyc":"^10.3.2","safe-publish-latest":"^2.0.0","tape":"^5.6.1"},"auto-changelog":{"output":"CHANGELOG.md","template":"keepachangelog","unreleased":false,"commitLimit":false,"backfillLimit":false,"hideCredit":true},"publishConfig":{"ignore":[".github/workflows"]},"gitHead":"51297fe55a81583cd11d34f2516f44ce6dd3724a","_id":"object.hasown@1.1.2","_nodeVersion":"19.0.1","_npmVersion":"8.19.2","dist":{"shasum":"f919e21fad4eb38a57bc6345b3afd496515c3f92","size":5908,"noattachment":false,"key":"/object.hasown/-/object.hasown-1.1.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/object.hasown/download/object.hasown-1.1.2.tgz"},"_npmUser":{"name":"ljharb","email":"ljharb@gmail.com"},"directories":{},"maintainers":[{"name":"ljharb","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/object.hasown_1.1.2_1667804967429_0.1515835726097614"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2022-11-07T07:10:39.395Z","publish_time":1667804967575,"_cnpm_publish_time":1667804967575},"1.1.1":{"name":"object.hasown","version":"1.1.1","description":"ES spec-compliant shim for Object.hasOwn","main":"index.js","exports":{".":[{"import":"./index.mjs","require":"./index.js","default":"./index.js"},"./index.js"],"./auto":"./auto.js","./polyfill":"./polyfill.js","./implementation":"./implementation.js","./shim":"./shim.js","./package.json":"./package.json"},"scripts":{"prepack":"npmignore --auto --commentLines=autogenerated","prepublish":"not-in-publish || npm run prepublishOnly","prepublishOnly":"safe-publish-latest","lint":"eslint --ext=js,mjs .","postlint":"es-shim-api --bound","pretest":"npm run lint","tests-only":"nyc tape 'test/**/*.js'","tests-esm":"nyc node test/index.mjs","test":"npm run tests-only && npm run tests-esm","posttest":"aud --production","version":"auto-changelog && git add CHANGELOG.md","postversion":"auto-changelog && git add CHANGELOG.md && git commit --no-edit --amend && git tag -f \"v$(node -e \"console.log(require('./package.json').version)\")\""},"repository":{"type":"git","url":"git+https://github.com/es-shims/Object.hasOwn.git"},"keywords":["Object","hasOwn","polyfill","shim","es-shim API"],"author":{"name":"Jordan Harband","email":"ljharb@gmail.com"},"funding":{"url":"https://github.com/sponsors/ljharb"},"license":"MIT","bugs":{"url":"https://github.com/es-shims/Object.hasOwn/issues"},"homepage":"https://github.com/es-shims/Object.hasOwn","dependencies":{"define-properties":"^1.1.4","es-abstract":"^1.19.5"},"devDependencies":{"@es-shims/api":"^2.2.3","@ljharb/eslint-config":"^20.2.3","aud":"^2.0.0","auto-changelog":"^2.4.0","call-bind":"^1.0.2","eslint":"=8.8.0","functions-have-names":"^1.2.3","has-strict-mode":"^1.0.1","has-symbols":"^1.0.3","npmignore":"^0.3.0","nyc":"^10.3.2","safe-publish-latest":"^2.0.0","tape":"^5.5.3"},"auto-changelog":{"output":"CHANGELOG.md","template":"keepachangelog","unreleased":false,"commitLimit":false,"backfillLimit":false,"hideCredit":true},"publishConfig":{"ignore":[".github/workflows"]},"gitHead":"f83034f72feb7823428faa92b34930810b3ff920","_id":"object.hasown@1.1.1","_nodeVersion":"18.0.0","_npmVersion":"8.3.1","dist":{"shasum":"ad1eecc60d03f49460600430d97f23882cf592a3","size":5755,"noattachment":false,"key":"/object.hasown/-/object.hasown-1.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/object.hasown/download/object.hasown-1.1.1.tgz"},"_npmUser":{"name":"ljharb","email":"ljharb@gmail.com"},"directories":{},"maintainers":[{"name":"ljharb","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/object.hasown_1.1.1_1651767262920_0.21642120739647797"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2022-05-05T16:59:46.110Z","publish_time":1651767263282,"_cnpm_publish_time":1651767263282},"1.1.0":{"name":"object.hasown","version":"1.1.0","description":"ES spec-compliant shim for Object.hasOwn","main":"index.js","exports":{".":[{"import":"./index.mjs","require":"./index.js","default":"./index.js"},"./index.js"],"./auto":"./auto.js","./shim":"./shim.js","./polyfill":"./polyfill.js","./implementation":"./implementation.js","./package.json":"./package.json"},"scripts":{"prepublish":"not-in-publish || npm run prepublishOnly","prepublishOnly":"safe-publish-latest","lint":"eslint .","postlint":"es-shim-api --bound","pretest":"npm run lint","tests-only":"nyc tape 'test/**/*.js'","tests-esm":"nyc node test/index.mjs","test":"npm run tests-only && npm run tests-esm","posttest":"aud --production","version":"auto-changelog && git add CHANGELOG.md","postversion":"auto-changelog && git add CHANGELOG.md && git commit --no-edit --amend && git tag -f \"v$(node -e \"console.log(require('./package.json').version)\")\""},"repository":{"type":"git","url":"git+https://github.com/es-shims/Object.hasOwn.git"},"keywords":["Object","hasOwn","polyfill","shim","es-shim API"],"author":{"name":"Jordan Harband","email":"ljharb@gmail.com"},"funding":{"url":"https://github.com/sponsors/ljharb"},"license":"MIT","bugs":{"url":"https://github.com/es-shims/Object.hasOwn/issues"},"homepage":"https://github.com/es-shims/Object.hasOwn","devDependencies":{"@es-shims/api":"^2.2.1","@ljharb/eslint-config":"^18.0.0","aud":"^1.1.5","auto-changelog":"^2.3.0","call-bind":"^1.0.2","eslint":"^7.32.0","functions-have-names":"^1.2.2","has-strict-mode":"^1.0.1","has-symbols":"^1.0.2","nyc":"^10.3.2","safe-publish-latest":"^1.1.4","tape":"^5.3.1"},"auto-changelog":{"output":"CHANGELOG.md","template":"keepachangelog","unreleased":false,"commitLimit":false,"backfillLimit":false,"hideCredit":true},"dependencies":{"define-properties":"^1.1.3","es-abstract":"^1.19.1"},"gitHead":"3b8befee46ae9ac940a3574260c4a6af234117f1","_id":"object.hasown@1.1.0","_nodeVersion":"16.10.0","_npmVersion":"7.24.0","dist":{"shasum":"7232ed266f34d197d15cac5880232f7a4790afe5","size":5253,"noattachment":false,"key":"/object.hasown/-/object.hasown-1.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/object.hasown/download/object.hasown-1.1.0.tgz"},"_npmUser":{"name":"ljharb","email":"ljharb@gmail.com"},"directories":{},"maintainers":[{"name":"ljharb","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/object.hasown_1.1.0_1633321704840_0.41208415399345166"},"_hasShrinkwrap":false,"publish_time":1633321705020,"_cnpm_publish_time":1633321705020},"1.0.0":{"name":"object.hasown","version":"1.0.0","description":"ES spec-compliant shim for Object.hasOwn","main":"index.js","exports":{".":[{"default":"./index.js"},"./index.js"],"./auto":[{"default":"./auto.js"},"./auto.js"],"./shim":[{"default":"./shim.js"},"./shim.js"],"./polyfill":[{"default":"./polyfill.js"},"./polyfill.js"],"./implementation":[{"default":"./implementation.js"},"./implementation.js"],"./package.json":"./package.json"},"scripts":{"prepublish":"not-in-publish || npm run prepublishOnly","prepublishOnly":"safe-publish-latest","lint":"eslint .","postlint":"es-shim-api --bound","pretest":"npm run lint","tests-only":"nyc tape 'test/**/*.js'","test":"npm run tests-only","posttest":"aud --production","version":"auto-changelog && git add CHANGELOG.md","postversion":"auto-changelog && git add CHANGELOG.md && git commit --no-edit --amend && git tag -f \"v$(node -e \"console.log(require('./package.json').version)\")\""},"repository":{"type":"git","url":"git+https://github.com/es-shims/Object.hasOwn.git"},"keywords":["Object","hasOwn","polyfill","shim","es-shim API"],"author":{"name":"Jordan Harband","email":"ljharb@gmail.com"},"funding":{"url":"https://github.com/sponsors/ljharb"},"license":"MIT","bugs":{"url":"https://github.com/es-shims/Object.hasOwn/issues"},"homepage":"https://github.com/es-shims/Object.hasOwn","devDependencies":{"@es-shims/api":"^2.1.2","@ljharb/eslint-config":"^17.5.1","aud":"^1.1.4","auto-changelog":"^2.2.1","call-bind":"^1.0.2","eslint":"^7.23.0","functions-have-names":"^1.2.2","has-strict-mode":"^1.0.1","has-symbols":"^1.0.2","nyc":"^10.3.2","safe-publish-latest":"^1.1.4","tape":"^5.2.2"},"auto-changelog":{"output":"CHANGELOG.md","template":"keepachangelog","unreleased":false,"commitLimit":false,"backfillLimit":false,"hideCredit":true},"dependencies":{"define-properties":"^1.1.3","es-abstract":"^1.18.1"},"gitHead":"c7dc5476f5cbb4ae7eb886218e5cbfb1d681119b","_id":"object.hasown@1.0.0","_nodeVersion":"16.1.0","_npmVersion":"7.11.2","dist":{"shasum":"bdbade33cfacfb25d7f26ae2b6cb870bf99905c2","size":4291,"noattachment":false,"key":"/object.hasown/-/object.hasown-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/object.hasown/download/object.hasown-1.0.0.tgz"},"_npmUser":{"name":"ljharb","email":"ljharb@gmail.com"},"directories":{},"maintainers":[{"name":"ljharb","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/object.hasown_1.0.0_1621969339988_0.1366979437971636"},"_hasShrinkwrap":false,"publish_time":1621969340123,"_cnpm_publish_time":1621969340123}},"readme":"# object.hasown <sup>[![Version Badge][npm-version-svg]][package-url]</sup>\n\n[![github actions][actions-image]][actions-url]\n[![coverage][codecov-image]][codecov-url]\n[![dependency status][deps-svg]][deps-url]\n[![dev dependency status][dev-deps-svg]][dev-deps-url]\n[![License][license-image]][license-url]\n[![Downloads][downloads-image]][downloads-url]\n\n[![npm badge][npm-badge-png]][package-url]\n\nAn ES spec-compliant `Object.hasOwn` shim. Invoke its \"shim\" method to shim `Object.hasOwn` if it is unavailable or noncompliant.\n\nThis package implements the [es-shim API](https://github.com/es-shims/api) interface. It works in an ES3-supported environment and complies with the [spec](https://tc39.es/proposal-accessible-object-hasownproperty/).\n\nMost common usage:\n```js\nvar assert = require('assert');\nvar hasOwn = require('object.hasown');\n\nvar obj = { a: 1, b: 2 };\n\nassert(hasOwn(obj, 'a'));\nassert(hasOwn(obj, 'b'));\nassert('toString' in obj && !hasOwn(obj, 'toString'));\n\nif (!Object.hasOwn) {\n\thasOwn.shim();\n}\n\nassert.deepEqual(Object.hasOwn(obj, 'a'), hasOwn(obj, 'a'));\n```\n\n## Tests\nSimply clone the repo, `npm install`, and run `npm test`\n\n[package-url]: https://npmjs.com/package/object.hasown\n[npm-version-svg]: https://versionbadg.es/es-shims/Object.hasOwn.svg\n[deps-svg]: https://david-dm.org/es-shims/Object.hasOwn.svg\n[deps-url]: https://david-dm.org/es-shims/Object.hasOwn\n[dev-deps-svg]: https://david-dm.org/es-shims/Object.hasOwn/dev-status.svg\n[dev-deps-url]: https://david-dm.org/es-shims/Object.hasOwn#info=devDependencies\n[npm-badge-png]: https://nodei.co/npm/object.hasown.png?downloads=true&stars=true\n[license-image]: https://img.shields.io/npm/l/object.hasown.svg\n[license-url]: LICENSE\n[downloads-image]: https://img.shields.io/npm/dm/object.hasown.svg\n[downloads-url]: https://npm-stat.com/charts.html?package=object.hasown\n[codecov-image]: https://codecov.io/gh/es-shims/Object.hasOwn/branch/main/graphs/badge.svg\n[codecov-url]: https://app.codecov.io/gh/es-shims/Object.hasOwn/\n[actions-image]: https://img.shields.io/endpoint?url=https://github-actions-badge-u3jn4tfpocch.runkit.sh/es-shims/Object.hasOwn\n[actions-url]: https://github.com/es-shims/Object.hasOwn/actions\n","_attachments":{},"homepage":"https://github.com/es-shims/Object.hasOwn","bugs":{"url":"https://github.com/es-shims/Object.hasOwn/issues"},"license":"MIT"}