{"_id":"data-view-buffer","_rev":"3744964","name":"data-view-buffer","description":"Get the ArrayBuffer out of a DataView, robustly.","dist-tags":{"latest":"1.0.2"},"maintainers":[{"name":"ljharb","email":""}],"time":{"modified":"2025-02-13T06:28:04.000Z","created":"2024-02-02T18:43:46.704Z","1.0.2":"2024-12-20T04:53:13.303Z","1.0.1":"2024-02-06T16:49:26.322Z","1.0.0":"2024-02-02T18:43:46.704Z"},"users":{},"author":{"name":"Jordan Harband","email":"ljharb@gmail.com"},"repository":{"type":"git","url":"git+https://github.com/inspect-js/data-view-buffer.git"},"versions":{"1.0.2":{"name":"data-view-buffer","version":"1.0.2","description":"Get the ArrayBuffer out of a DataView, robustly.","main":"index.js","exports":{".":"./index.js","./package.json":"./package.json"},"types":"./index.d.ts","sideEffects":false,"scripts":{"prepack":"npmignore --auto --commentLines=autogenerated","prepublishOnly":"safe-publish-latest","prepublish":"not-in-publish || npm run prepublishOnly","prelint":"evalmd README.md","lint":"eslint --ext=js,mjs .","postlint":"tsc -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)\")\""},"funding":{"url":"https://github.com/sponsors/ljharb"},"repository":{"type":"git","url":"git+https://github.com/inspect-js/data-view-buffer.git"},"keywords":["javascript","ecmascript","dataview","buffer","robust"],"author":{"name":"Jordan Harband","email":"ljharb@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/inspect-js/data-view-buffer/issues"},"homepage":"https://github.com/inspect-js/data-view-buffer#readme","dependencies":{"call-bound":"^1.0.3","es-errors":"^1.3.0","is-data-view":"^1.0.2"},"devDependencies":{"@ljharb/eslint-config":"^21.1.1","@ljharb/tsconfig":"^0.2.2","@types/es-value-fixtures":"^1.4.4","@types/for-each":"^0.3.3","@types/object-inspect":"^1.13.0","@types/tape":"^5.8.0","auto-changelog":"^2.5.0","encoding":"^0.1.13","es-value-fixtures":"^1.5.0","eslint":"=8.8.0","evalmd":"^0.0.19","for-each":"^0.3.3","in-publish":"^2.0.1","npmignore":"^0.3.1","nyc":"^10.3.2","object-inspect":"^1.13.3","safe-publish-latest":"^2.0.0","tape":"^5.9.0","typescript":"next"},"engines":{"node":">= 0.4"},"auto-changelog":{"output":"CHANGELOG.md","template":"keepachangelog","unreleased":false,"commitLimit":false,"backfillLimit":false,"hideCredit":true},"publishConfig":{"ignore":[".github/workflows"]},"_id":"data-view-buffer@1.0.2","gitHead":"38603a5b40cc02824054ec549cbf4a14c96cca41","_nodeVersion":"23.5.0","_npmVersion":"10.9.2","dist":{"shasum":"211a03ba95ecaf7798a8c7198d79536211f88570","size":4903,"noattachment":false,"key":"/data-view-buffer/-/data-view-buffer-1.0.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/data-view-buffer/download/data-view-buffer-1.0.2.tgz"},"_npmUser":{"name":"ljharb","email":"ljharb@gmail.com"},"directories":{},"maintainers":[{"name":"ljharb","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/data-view-buffer_1.0.2_1734670393091_0.4974852316963856"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2024-12-20T04:53:13.303Z","publish_time":1734670393303,"_source_registry_name":"default","_cnpm_publish_time":1734670393303},"1.0.1":{"name":"data-view-buffer","version":"1.0.1","description":"Get the ArrayBuffer out of a DataView, robustly.","main":"index.js","exports":{".":"./index.js","./package.json":"./package.json"},"types":"./index.d.ts","sideEffects":false,"scripts":{"prepack":"npmignore --auto --commentLines=autogenerated","prepublishOnly":"safe-publish-latest","prepublish":"not-in-publish || npm run prepublishOnly","prelint":"evalmd README.md","lint":"eslint --ext=js,mjs .","postlint":"tsc -p .","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)\")\""},"funding":{"url":"https://github.com/sponsors/ljharb"},"repository":{"type":"git","url":"git+https://github.com/ljharb/data-view-buffer.git"},"keywords":["javascript","ecmascript","dataview","buffer","robust"],"author":{"name":"Jordan Harband","email":"ljharb@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/ljharb/data-view-buffer/issues"},"homepage":"https://github.com/ljharb/data-view-buffer#readme","dependencies":{"call-bind":"^1.0.6","es-errors":"^1.3.0","is-data-view":"^1.0.1"},"devDependencies":{"@ljharb/eslint-config":"^21.1.0","@types/call-bind":"^1.0.5","@types/es-value-fixtures":"^1.4.4","@types/for-each":"^0.3.3","@types/object-inspect":"^1.8.4","@types/tape":"^5.6.4","aud":"^2.0.4","auto-changelog":"^2.4.0","es-value-fixtures":"^1.4.2","eslint":"=8.8.0","evalmd":"^0.0.19","for-each":"^0.3.3","in-publish":"^2.0.1","npmignore":"^0.3.1","nyc":"^10.3.2","object-inspect":"^1.13.1","safe-publish-latest":"^2.0.0","tape":"^5.7.4","typescript":"next"},"engines":{"node":">= 0.4"},"auto-changelog":{"output":"CHANGELOG.md","template":"keepachangelog","unreleased":false,"commitLimit":false,"backfillLimit":false,"hideCredit":true},"publishConfig":{"ignore":[".github/workflows"]},"_id":"data-view-buffer@1.0.1","gitHead":"a8c86803b495d4c46fd35b7c4fd84a5da1eb2e5c","_nodeVersion":"21.6.0","_npmVersion":"10.2.4","dist":{"shasum":"8ea6326efec17a2e42620696e671d7d5a8bc66b2","size":5354,"noattachment":false,"key":"/data-view-buffer/-/data-view-buffer-1.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/data-view-buffer/download/data-view-buffer-1.0.1.tgz"},"_npmUser":{"name":"ljharb","email":"ljharb@gmail.com"},"directories":{},"maintainers":[{"name":"ljharb","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/data-view-buffer_1.0.1_1707238166136_0.31742586551228213"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2024-02-06T16:49:26.322Z","publish_time":1707238166322,"_source_registry_name":"default","_cnpm_publish_time":1707238166322},"1.0.0":{"name":"data-view-buffer","version":"1.0.0","description":"Get the ArrayBuffer out of a DataView, robustly.","main":"index.js","exports":{".":"./index.js","./package.json":"./package.json"},"types":"./index.d.ts","sideEffects":false,"scripts":{"prepack":"npmignore --auto --commentLines=autogenerated","prepublishOnly":"safe-publish-latest","prepublish":"not-in-publish || npm run prepublishOnly","prelint":"evalmd README.md","lint":"eslint --ext=js,mjs .","postlint":"tsc -p .","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)\")\""},"funding":{"url":"https://github.com/sponsors/ljharb"},"repository":{"type":"git","url":"git+https://github.com/ljharb/data-view-buffer.git"},"keywords":["javascript","ecmascript","dataview","buffer","robust"],"author":{"name":"Jordan Harband","email":"ljharb@gmail.com"},"license":"MIT","bugs":{"url":"https://github.com/ljharb/data-view-buffer/issues"},"homepage":"https://github.com/ljharb/data-view-buffer#readme","dependencies":{"call-bind":"^1.0.5","get-intrinsic":"^1.2.2","is-data-view":"^1.0.1"},"devDependencies":{"@ljharb/eslint-config":"^21.1.0","@types/call-bind":"^1.0.5","@types/es-value-fixtures":"^1.4.4","@types/for-each":"^0.3.3","@types/get-intrinsic":"^1.2.2","@types/object-inspect":"^1.8.4","@types/tape":"^5.6.4","aud":"^2.0.4","auto-changelog":"^2.4.0","es-value-fixtures":"^1.4.2","eslint":"=8.8.0","evalmd":"^0.0.19","for-each":"^0.3.3","in-publish":"^2.0.1","npmignore":"^0.3.1","nyc":"^10.3.2","object-inspect":"^1.13.1","safe-publish-latest":"^2.0.0","tape":"^5.7.4","typescript":"next"},"engines":{"node":">= 0.4"},"auto-changelog":{"output":"CHANGELOG.md","template":"keepachangelog","unreleased":false,"commitLimit":false,"backfillLimit":false,"hideCredit":true},"publishConfig":{"ignore":[".github/workflows"]},"_id":"data-view-buffer@1.0.0","gitHead":"3f868e2f2384eb7ece0b49ff05e77564f4e2b5c3","_nodeVersion":"21.6.0","_npmVersion":"10.2.4","dist":{"shasum":"00d85ffb5ba5a03b56552e6978e3cb487b1a42a8","size":5205,"noattachment":false,"key":"/data-view-buffer/-/data-view-buffer-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/data-view-buffer/download/data-view-buffer-1.0.0.tgz"},"_npmUser":{"name":"ljharb","email":"ljharb@gmail.com"},"directories":{},"maintainers":[{"name":"ljharb","email":""}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/data-view-buffer_1.0.0_1706899426570_0.8576958370884347"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2024-02-02T18:43:46.704Z","publish_time":1706899426704,"_source_registry_name":"default","_cnpm_publish_time":1706899426704}},"readme":"# data-view-buffer <sup>[![Version Badge][npm-version-svg]][package-url]</sup>\n\n[![github actions][actions-image]][actions-url]\n[![coverage][codecov-image]][codecov-url]\n[![License][license-image]][license-url]\n[![Downloads][downloads-image]][downloads-url]\n\n[![npm badge][npm-badge-png]][package-url]\n\nGet the ArrayBuffer out of a DataView, robustly.\n\nThis will work in node <= 0.10 and < 0.11.4, where there's no prototype accessor, only a nonconfigurable own property.\nIt will also work in modern engines where `DataView.prototype.buffer` has been deleted after this module has loaded.\n\n## Example\n\n```js\nconst dataViewBuffer = require('data-view-buffer');\nconst assert = require('assert');\n\nconst ab = new ArrayBuffer(0);\nconst dv = new DataView(ab);\nassert.equal(dataViewBuffer(dv), ab);\n```\n\n## Tests\nSimply clone the repo, `npm install`, and run `npm test`\n\n[package-url]: https://npmjs.org/package/data-view-buffer\n[npm-version-svg]: https://versionbadg.es/inspect-js/data-view-buffer.svg\n[deps-svg]: https://david-dm.org/inspect-js/data-view-buffer.svg\n[deps-url]: https://david-dm.org/inspect-js/data-view-buffer\n[dev-deps-svg]: https://david-dm.org/inspect-js/data-view-buffer/dev-status.svg\n[dev-deps-url]: https://david-dm.org/inspect-js/data-view-buffer#info=devDependencies\n[npm-badge-png]: https://nodei.co/npm/data-view-buffer.png?downloads=true&stars=true\n[license-image]: https://img.shields.io/npm/l/data-view-buffer.svg\n[license-url]: LICENSE\n[downloads-image]: https://img.shields.io/npm/dm/data-view-buffer.svg\n[downloads-url]: https://npm-stat.com/charts.html?package=data-view-buffer\n[codecov-image]: https://codecov.io/gh/inspect-js/data-view-buffer/branch/main/graphs/badge.svg\n[codecov-url]: https://app.codecov.io/gh/inspect-js/data-view-buffer/\n[actions-image]: https://img.shields.io/endpoint?url=https://github-actions-badge-u3jn4tfpocch.runkit.sh/inspect-js/data-view-buffer\n[actions-url]: https://github.com/inspect-js/data-view-buffer/actions\n","_attachments":{},"homepage":"https://github.com/inspect-js/data-view-buffer#readme","bugs":{"url":"https://github.com/inspect-js/data-view-buffer/issues"},"license":"MIT"}