{"name":"unbox-primitive","version":"1.1.0","description":"Unbox a boxed JS primitive value.","main":"index.js","scripts":{"prepack":"npmignore --auto --commentLines=autogenerated","prepublish":"not-in-publish || npm run prepublishOnly","prepublishOnly":"safe-publish-latest","lint":"eslint --ext=js,mjs .","postlint":"tsc && attw -P","pretest":"npm run lint","tests-only":"nyc tape 'test/**/*.js'","test":"npm run tests-only","posttest":"npx npm@'>= 10.2' audit --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/ljharb/unbox-primitive.git"},"keywords":["unbox","boxed","primitive","object","javascript","ecmascript"],"author":{"name":"Jordan Harband","email":"ljharb@gmail.com"},"funding":{"url":"https://github.com/sponsors/ljharb"},"license":"MIT","bugs":{"url":"https://github.com/ljharb/unbox-primitive/issues"},"homepage":"https://github.com/ljharb/unbox-primitive#readme","devDependencies":{"@arethetypeswrong/cli":"^0.17.1","@ljharb/eslint-config":"^21.1.1","@ljharb/tsconfig":"^0.2.2","@types/for-each":"^0.3.3","@types/object-inspect":"^1.13.0","@types/object-is":"^1.1.0","@types/tape":"^5.7.0","auto-changelog":"^2.5.0","encoding":"^0.1.13","es-value-fixtures":"^1.5.0","eslint":"=8.8.0","for-each":"^0.3.3","in-publish":"^2.0.1","npmignore":"^0.3.1","nyc":"^10.3.2","object-inspect":"^1.13.3","object-is":"^1.1.6","safe-publish-latest":"^2.0.0","tape":"^5.9.0","typescript":"next"},"dependencies":{"call-bound":"^1.0.3","has-bigints":"^1.0.2","has-symbols":"^1.1.0","which-boxed-primitive":"^1.1.1"},"auto-changelog":{"output":"CHANGELOG.md","template":"keepachangelog","unreleased":false,"commitLimit":false,"backfillLimit":false,"hideCredit":true},"publishConfig":{"ignore":[".github/workflows"]},"engines":{"node":">= 0.4"},"_id":"unbox-primitive@1.1.0","gitHead":"07ce64a97a0aa8d745e172f26f49eff863adae01","types":"./index.d.ts","_nodeVersion":"23.4.0","_npmVersion":"10.9.2","dist":{"integrity":"sha512-nWJ91DjeOkej/TA8pXQ3myruKpKEYgqvpw9lz4OPHj/NWFNluYrjbz9j01CJ8yKQd2g4jFoOkINCTW2I5LEEyw==","shasum":"8d9d2c9edeea8460c7f35033a88867944934d1e2","tarball":"http://registry-npm.ywwl.com/unbox-primitive/download/unbox-primitive-1.1.0.tgz","fileCount":12,"unpackedSize":18507,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCSZ3dE5b2E5Th0Akf2ACF8dinAdgD1DcEhxAAGxmLIFQIgQzeihwu4oYxb18ZtL9yvdmy3LC/d3B+FhthRpPyc/nM="}],"size":7004,"noattachment":false,"key":"/unbox-primitive/-/unbox-primitive-1.1.0.tgz"},"_npmUser":{"name":"ljharb","email":"ljharb@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/unbox-primitive_1.1.0_1734331503530_0.6715002574996403"},"_hasShrinkwrap":false,"readme":"# unbox-primitive <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\nUnbox a boxed JS primitive value. This module works cross-realm/iframe, does not depend on `instanceof` or mutable properties, and works despite ES6 Symbol.toStringTag.\n\n## Example\n\n```js\nvar unboxPrimitive = require('unbox-primitive');\nvar assert = require('assert');\n\nassert.equal(unboxPrimitive(new Boolean(false)), false);\nassert.equal(unboxPrimitive(new String('f')), 'f');\nassert.equal(unboxPrimitive(new Number(42)), 42);\nconst s = Symbol();\nassert.equal(unboxPrimitive(Object(s)), s);\nassert.equal(unboxPrimitive(new BigInt(42)), 42n);\n\n// any primitive, or non-boxed-primitive object, will throw\n```\n\n## Tests\nSimply clone the repo, `npm install`, and run `npm test`\n\n[package-url]: https://npmjs.org/package/unbox-primitive\n[npm-version-svg]: https://versionbadg.es/ljharb/unbox-primitive.svg\n[deps-svg]: https://david-dm.org/ljharb/unbox-primitive.svg\n[deps-url]: https://david-dm.org/ljharb/unbox-primitive\n[dev-deps-svg]: https://david-dm.org/ljharb/unbox-primitive/dev-status.svg\n[dev-deps-url]: https://david-dm.org/ljharb/unbox-primitive#info=devDependencies\n[npm-badge-png]: https://nodei.co/npm/unbox-primitive.png?downloads=true&stars=true\n[license-image]: https://img.shields.io/npm/l/unbox-primitive.svg\n[license-url]: LICENSE\n[downloads-image]: https://img.shields.io/npm/dm/unbox-primitive.svg\n[downloads-url]: https://npm-stat.com/charts.html?package=unbox-primitive\n[codecov-image]: https://codecov.io/gh/ljharb/unbox-primitive/branch/main/graphs/badge.svg\n[codecov-url]: https://app.codecov.io/gh/ljharb/unbox-primitive/\n[actions-image]: https://img.shields.io/endpoint?url=https://github-actions-badge-u3jn4tfpocch.runkit.sh/ljharb/unbox-primitive\n[actions-url]: https://github.com/ljharb/unbox-primitive/actions\n","publish_time":1734331503707,"maintainers":[{"name":"ljharb","email":"ljharb@gmail.com"}],"_cnpm_publish_time":1734331503707,"dist-tags":{"latest":"1.1.0"}}