pax_global_header 0000666 0000000 0000000 00000000064 14730207007 0014512 g ustar 00root root 0000000 0000000 52 comment=70c53e754ed22940db463c10ec40d7bda8546a79
inspect-js-is-finalizationregistry-bcac67b/ 0000775 0000000 0000000 00000000000 14730207007 0021231 5 ustar 00root root 0000000 0000000 inspect-js-is-finalizationregistry-bcac67b/.eslintrc 0000664 0000000 0000000 00000000116 14730207007 0023053 0 ustar 00root root 0000000 0000000 {
"root": true,
"extends": "@ljharb",
"rules": {
"id-length": 0,
},
}
inspect-js-is-finalizationregistry-bcac67b/.github/ 0000775 0000000 0000000 00000000000 14730207007 0022571 5 ustar 00root root 0000000 0000000 inspect-js-is-finalizationregistry-bcac67b/.github/FUNDING.yml 0000664 0000000 0000000 00000001122 14730207007 0024402 0 ustar 00root root 0000000 0000000 # These are supported funding model platforms
github: [ljharb]
patreon: # Replace with a single Patreon username
open_collective: # Replace with a single Open Collective username
ko_fi: # Replace with a single Ko-fi username
tidelift: npm/is-finalizationregistry
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
otechie: # Replace with a single Otechie username
custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
inspect-js-is-finalizationregistry-bcac67b/.github/workflows/ 0000775 0000000 0000000 00000000000 14730207007 0024626 5 ustar 00root root 0000000 0000000 inspect-js-is-finalizationregistry-bcac67b/.github/workflows/node-aught.yml 0000664 0000000 0000000 00000000516 14730207007 0027406 0 ustar 00root root 0000000 0000000 name: 'Tests: node.js < 10'
on: [pull_request, push]
jobs:
tests:
uses: ljharb/actions/.github/workflows/node.yml@main
with:
range: '< 10'
type: minors
command: npm run tests-only
node:
name: 'node < 10'
needs: [tests]
runs-on: ubuntu-latest
steps:
- run: 'echo tests completed'
inspect-js-is-finalizationregistry-bcac67b/.github/workflows/node-pretest.yml 0000664 0000000 0000000 00000000206 14730207007 0027760 0 ustar 00root root 0000000 0000000 name: 'Tests: pretest/posttest'
on: [pull_request, push]
jobs:
tests:
uses: ljharb/actions/.github/workflows/pretest.yml@main
inspect-js-is-finalizationregistry-bcac67b/.github/workflows/node-tens.yml 0000664 0000000 0000000 00000000547 14730207007 0027253 0 ustar 00root root 0000000 0000000 name: 'Tests: node.js 10 - 20'
on: [pull_request, push]
permissions:
contents: read
jobs:
tests:
uses: ljharb/actions/.github/workflows/node.yml@main
with:
range: '>= 10 < 20'
type: minors
command: npm run tests-only
node:
name: 'node 10 - 20'
needs: [tests]
runs-on: ubuntu-latest
steps:
- run: true
inspect-js-is-finalizationregistry-bcac67b/.github/workflows/node-twenties.yml 0000664 0000000 0000000 00000000536 14730207007 0030142 0 ustar 00root root 0000000 0000000 name: 'Tests: node.js >= 20'
on: [pull_request, push]
permissions:
contents: read
jobs:
tests:
uses: ljharb/actions/.github/workflows/node.yml@main
with:
range: '>= 20'
type: minors
command: npm run tests-only
node:
name: 'node >= 20'
needs: [tests]
runs-on: ubuntu-latest
steps:
- run: true
inspect-js-is-finalizationregistry-bcac67b/.github/workflows/rebase.yml 0000664 0000000 0000000 00000000257 14730207007 0026616 0 ustar 00root root 0000000 0000000 name: Automatic Rebase
on: [pull_request_target]
jobs:
_:
uses: ljharb/actions/.github/workflows/rebase.yml@main
secrets:
token: ${{ secrets.GITHUB_TOKEN }}
inspect-js-is-finalizationregistry-bcac67b/.github/workflows/require-allow-edits.yml 0000664 0000000 0000000 00000000303 14730207007 0031243 0 ustar 00root root 0000000 0000000 name: Require “Allow Edits”
on: [pull_request_target]
jobs:
_:
name: "Require “Allow Edits”"
runs-on: ubuntu-latest
steps:
- uses: ljharb/require-allow-edits@main
inspect-js-is-finalizationregistry-bcac67b/.gitignore 0000664 0000000 0000000 00000003251 14730207007 0023222 0 ustar 00root root 0000000 0000000 # Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
lerna-debug.log*
# Diagnostic reports (https://nodejs.org/api/report.html)
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
# Runtime data
pids
*.pid
*.seed
*.pid.lock
# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov
# Coverage directory used by tools like istanbul
coverage
*.lcov
# nyc test coverage
.nyc_output
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
.grunt
# Bower dependency directory (https://bower.io/)
bower_components
# node-waf configuration
.lock-wscript
# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release
# Dependency directories
node_modules/
jspm_packages/
# TypeScript v1 declaration files
typings/
# TypeScript cache
*.tsbuildinfo
# Optional npm cache directory
.npm
# Optional eslint cache
.eslintcache
# Microbundle cache
.rpt2_cache/
.rts2_cache_cjs/
.rts2_cache_es/
.rts2_cache_umd/
# Optional REPL history
.node_repl_history
# Output of 'npm pack'
*.tgz
# Yarn Integrity file
.yarn-integrity
# dotenv environment variables file
.env
.env.test
# parcel-bundler cache (https://parceljs.org/)
.cache
# Next.js build output
.next
# Nuxt.js build / generate output
.nuxt
dist
# Gatsby files
.cache/
# Comment in the public line in if your project uses Gatsby and *not* Next.js
# https://nextjs.org/blog/next-9-1#public-directory-support
# public
# vuepress build output
.vuepress/dist
# Serverless directories
.serverless/
# FuseBox cache
.fusebox/
# DynamoDB Local files
.dynamodb/
# TernJS port file
.tern-port
# Only apps should have lockfiles
npm-shrinkwrap.json
package-lock.json
yarn.lock
.npmignore
inspect-js-is-finalizationregistry-bcac67b/.npmrc 0000664 0000000 0000000 00000000067 14730207007 0022354 0 ustar 00root root 0000000 0000000 package-lock=false
allow-same-version=true
message=v%s
inspect-js-is-finalizationregistry-bcac67b/.nycrc 0000664 0000000 0000000 00000000213 14730207007 0022344 0 ustar 00root root 0000000 0000000 {
"all": true,
"check-coverage": false,
"reporter": ["text-summary", "text", "html", "json"],
"exclude": [
"coverage",
"test"
]
}
inspect-js-is-finalizationregistry-bcac67b/CHANGELOG.md 0000664 0000000 0000000 00000020250 14730207007 0023041 0 ustar 00root root 0000000 0000000 # Changelog
All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [v1.1.1](https://github.com/inspect-js/is-finalizationregistry/compare/v1.1.0...v1.1.1) - 2024-12-16
### Commits
- [actions] re-add finishers [`0f41639`](https://github.com/inspect-js/is-finalizationregistry/commit/0f41639657eb79da783ab99246ffbab97ce52785)
- [Dev Deps] update `@arethetypeswrong/cli`, `@ljharb/tsconfig`, `@types/tape` [`1467f11`](https://github.com/inspect-js/is-finalizationregistry/commit/1467f11d2b638ae72ab5fff33a72c88143ed9546)
- [meta] sort package.json [`bd48b68`](https://github.com/inspect-js/is-finalizationregistry/commit/bd48b686cf499ae590404729b4d3a6fca9c9d0f3)
- [Refactor] use `call-bound` directly [`ce9dcd4`](https://github.com/inspect-js/is-finalizationregistry/commit/ce9dcd4abea4d17ca63b2d46385d78bebaf05d84)
- [Deps] update `call-bind` [`9b8daac`](https://github.com/inspect-js/is-finalizationregistry/commit/9b8daac5237a420ec8de65222d1b14e56de55b50)
- [meta] add `sideEffects` flag [`c5cb18b`](https://github.com/inspect-js/is-finalizationregistry/commit/c5cb18b51f22a52dcdc17afc3ce02a1ace41d418)
## [v1.1.0](https://github.com/inspect-js/is-finalizationregistry/compare/v1.0.2...v1.1.0) - 2024-11-23
### Commits
- [actions] reuse common workflows [`b9b56fe`](https://github.com/inspect-js/is-finalizationregistry/commit/b9b56fe405d0385fcbcc587abcf7b6f0c5b4e7be)
- [meta] use `npmignore` to autogenerate an npmignore file [`4b65c3d`](https://github.com/inspect-js/is-finalizationregistry/commit/4b65c3dfe532ba3d1130f9bd7d36d674790b836d)
- [New] add TS types [`22c7c81`](https://github.com/inspect-js/is-finalizationregistry/commit/22c7c81612a906c787432a0c70df27c2a278f370)
- [actions] split out node 10-20, and 20+ [`b4bc95a`](https://github.com/inspect-js/is-finalizationregistry/commit/b4bc95a923323b9064965442f2a5646c1ec4b99b)
- [Dev Deps] update `eslint`, `@ljharb/eslint-config`, `object-inspect`, `safe-publish-latest`, `tape` [`25d2e81`](https://github.com/inspect-js/is-finalizationregistry/commit/25d2e815627d5549bbd366fd95dcd134f99fc16d)
- [Dev Deps] update `eslint`, `@ljharb/eslint-config`, `aud`, `auto-changelog`, `object-inspect`, `tape` [`a045ec6`](https://github.com/inspect-js/is-finalizationregistry/commit/a045ec6d56106561232bd7dbd95c058d195cd3d9)
- [actions] update rebase action to use reusable workflow [`14ee45b`](https://github.com/inspect-js/is-finalizationregistry/commit/14ee45b34361a4a14cfc444a71601e55ddd98a6e)
- [actions] update codecov uploader [`d37bfcb`](https://github.com/inspect-js/is-finalizationregistry/commit/d37bfcb43695e56c06829b05051f5b5f4cdbcd6b)
- [Dev Deps] update `@ljharb/eslint-config`, `auto-changelog`, `npmignore`, `object-inspect`, `tape` [`a36b69c`](https://github.com/inspect-js/is-finalizationregistry/commit/a36b69c8f1a43beb07416658609b9950e58bb615)
- [meta] clean up `exports` [`35b3562`](https://github.com/inspect-js/is-finalizationregistry/commit/35b35627f8234e76a92e72669f7c5041e2c4074b)
- [meta] add missing `engines.node` [`0603193`](https://github.com/inspect-js/is-finalizationregistry/commit/06031931c5f4e672f47463da2c7b43b45a629819)
- [Tests] replace `aud` with `npm audit` [`05b4596`](https://github.com/inspect-js/is-finalizationregistry/commit/05b459606f22cebe6a42101438bfcdae68313786)
- [Deps] update `call-bind` [`6482025`](https://github.com/inspect-js/is-finalizationregistry/commit/6482025cba84cff2b51db51768ed6d391f01335d)
- [Dev Deps] add missing peer dep [`90f97dd`](https://github.com/inspect-js/is-finalizationregistry/commit/90f97ddc8998ead46f26d8b2fa0fd8be17ea48bb)
## [v1.0.2](https://github.com/inspect-js/is-finalizationregistry/compare/v1.0.1...v1.0.2) - 2021-10-05
### Commits
- [meta] do not publish Github Actions workflows [`5509e8c`](https://github.com/inspect-js/is-finalizationregistry/commit/5509e8c13173a128244fc306d304c9be958b62f3)
- [actions] use `node/install` instead of `node/run`; use `codecov` action [`b566204`](https://github.com/inspect-js/is-finalizationregistry/commit/b5662048c9824089baf6fe3e0c408d6297635b2c)
- [readme] fix markdown [`02602dd`](https://github.com/inspect-js/is-finalizationregistry/commit/02602dda3176944f6681b97fb0d26e43bf2accc8)
- [Fix] use `call-bind` and obviate missing `es-abstract` dep [`9d71846`](https://github.com/inspect-js/is-finalizationregistry/commit/9d718467ef713e10242c28e48d82947d108ed5ef)
- [readme] add actions and codecov badges [`75381a7`](https://github.com/inspect-js/is-finalizationregistry/commit/75381a76ad373fd4bea0f032e8593dec60785332)
- [Dev Deps] update `eslint`, `@ljharb/eslint-config`, `auto-changelog`, `object-inspect`, `tape` [`7a0f9d8`](https://github.com/inspect-js/is-finalizationregistry/commit/7a0f9d8befeee03f578cf9184190e4a143a05abf)
- [Dev Deps] update `eslint`, `@ljharb/eslint-config`, `aud`, `object-inspect`, `tape` [`962689f`](https://github.com/inspect-js/is-finalizationregistry/commit/962689f01c33d06eadb4456004d231b56cb13825)
- [Dev Deps] update `eslint`, `@ljharb/eslint-config`, `tape` [`762ebf2`](https://github.com/inspect-js/is-finalizationregistry/commit/762ebf2f8d06597029b794053f0630b6ddeb7cc2)
- [meta] add `safe-publish-latest`; use `prepublishOnly` script for npm 7+ [`fe0b226`](https://github.com/inspect-js/is-finalizationregistry/commit/fe0b2268e0eaa4fd56418aba87d2e761c04917e6)
## [v1.0.1](https://github.com/inspect-js/is-finalizationregistry/compare/v1.0.0...v1.0.1) - 2020-12-04
### Commits
- [Tests] migrate tests to Github Actions [`b697250`](https://github.com/inspect-js/is-finalizationregistry/commit/b69725063681eeb9179d9945512a62112b360cd2)
- [Tests] run `nyc` on all tests [`9091806`](https://github.com/inspect-js/is-finalizationregistry/commit/9091806c8cc05340dc964fb3c566e650c1bff947)
- [actions] add "Allow Edits" workflow [`5d8c4f5`](https://github.com/inspect-js/is-finalizationregistry/commit/5d8c4f5e5ca4f001f6a16744c2cce5d32bdae39b)
- [Dev Deps] update `eslint`, `@ljharb/eslint-config`, `aud`, `auto-changelog`, `object-inspect` [`3af34c1`](https://github.com/inspect-js/is-finalizationregistry/commit/3af34c194a8dfb41e773f7e1647e1e1cf05ec98d)
- [actions] switch Automatic Rebase workflow to `pull_request_target` event [`d0720ff`](https://github.com/inspect-js/is-finalizationregistry/commit/d0720ff2d07308ec3e90f13c7a15affa05339fe7)
- [readme] remove travis badge [`2757b27`](https://github.com/inspect-js/is-finalizationregistry/commit/2757b27db4cbb93d712bd85c1741f3071a720dc7)
- [meta] add `package.json` to `exports` [`c680142`](https://github.com/inspect-js/is-finalizationregistry/commit/c680142dcd73d3f3c8ec75c0ab1c9281edaeb91f)
## v1.0.0 - 2020-08-02
### Commits
- Initial commit [`094a595`](https://github.com/inspect-js/is-finalizationregistry/commit/094a59522ab29b1701ad2f1cb67ee01f1e68cae2)
- readme [`38d75fd`](https://github.com/inspect-js/is-finalizationregistry/commit/38d75fd9d38106b6a4d09bdb4ac5c5ca186c62de)
- Tests [`1052cd2`](https://github.com/inspect-js/is-finalizationregistry/commit/1052cd21bfa90e83e5fbf656ce67f3c038aa9336)
- npm init [`307016d`](https://github.com/inspect-js/is-finalizationregistry/commit/307016d5228e184a22a1ee2992f24ed208c3cec6)
- Implementation [`48df57a`](https://github.com/inspect-js/is-finalizationregistry/commit/48df57a25d3cde99f43a46fe458e878f79179520)
- [meta] add auto-changelog [`cd1c8e1`](https://github.com/inspect-js/is-finalizationregistry/commit/cd1c8e1f97a499a0ea7edc6e7afde3b522fb8329)
- [actions] add automatic rebasing / merge commit blocking [`d6c9220`](https://github.com/inspect-js/is-finalizationregistry/commit/d6c92207d7f76785dada19e09b937326dc3b499d)
- [meta] add "funding"; create `FUNDING.yml` [`0e74e10`](https://github.com/inspect-js/is-finalizationregistry/commit/0e74e10f3667b1f8c9ea2a7a3dba67b373a17902)
- [Tests] add `npm run lint` [`edb8d13`](https://github.com/inspect-js/is-finalizationregistry/commit/edb8d138a6350b0fb7f398657125c74f218c547f)
- [Tests] use shared travis-ci configs [`8eb7a3a`](https://github.com/inspect-js/is-finalizationregistry/commit/8eb7a3a0a45e5aab60edb385ddee2e7bd1e22d81)
- Only apps should have lockfiles [`566b021`](https://github.com/inspect-js/is-finalizationregistry/commit/566b021e66bc2325e12f88324174413348cb987d)
inspect-js-is-finalizationregistry-bcac67b/LICENSE 0000664 0000000 0000000 00000002053 14730207007 0022236 0 ustar 00root root 0000000 0000000 MIT License
Copyright (c) 2020 Inspect JS
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
inspect-js-is-finalizationregistry-bcac67b/README.md 0000664 0000000 0000000 00000005104 14730207007 0022510 0 ustar 00root root 0000000 0000000 # is-finalizationregistry [![Version Badge][npm-version-svg]][package-url]
[![github actions][actions-image]][actions-url]
[![coverage][codecov-image]][codecov-url]
[![dependency status][deps-svg]][deps-url]
[![dev dependency status][dev-deps-svg]][dev-deps-url]
[![License][license-image]][license-url]
[![Downloads][downloads-image]][downloads-url]
[![npm badge][npm-badge-png]][package-url]
Is this value a JS FinalizationRegistry? This module works cross-realm/iframe, and despite ES6 @@toStringTag.
## Example
```js
var isFinalizationRegistry = require('is-finalizationregistry');
assert(!isFinalizationRegistry(function () {}));
assert(!isFinalizationRegistry(null));
assert(!isFinalizationRegistry(function* () { yield 42; return Infinity; });
assert(!isFinalizationRegistry(Symbol('foo')));
assert(!isFinalizationRegistry(1n));
assert(!isFinalizationRegistry(Object(1n)));
assert(!isFinalizationRegistry(new Set()));
assert(!isFinalizationRegistry(new WeakSet()));
assert(!isFinalizationRegistry(new Map()));
assert(!isFinalizationRegistry(new WeakMap()));
assert(!isFinalizationRegistry(new WeakRef({})));
assert(isFinalizationRegistry(new FinalizationRegistry(function () {})));
class MyFinalizationRegistry extends FinalizationRegistry {}
assert(isFinalizationRegistry(new MyFinalizationRegistry(function () {})));
```
## Tests
Simply clone the repo, `npm install`, and run `npm test`
[package-url]: https://npmjs.org/package/is-finalizationregistry
[npm-version-svg]: https://versionbadg.es/inspect-js/is-finalizationregistry.svg
[deps-svg]: https://david-dm.org/inspect-js/is-finalizationregistry.svg
[deps-url]: https://david-dm.org/inspect-js/is-finalizationregistry
[dev-deps-svg]: https://david-dm.org/inspect-js/is-finalizationregistry/dev-status.svg
[dev-deps-url]: https://david-dm.org/inspect-js/is-finalizationregistry#info=devDependencies
[npm-badge-png]: https://nodei.co/npm/is-finalizationregistry.png?downloads=true&stars=true
[license-image]: https://img.shields.io/npm/l/is-finalizationregistry.svg
[license-url]: LICENSE
[downloads-image]: https://img.shields.io/npm/dm/is-finalizationregistry.svg
[downloads-url]: https://npm-stat.com/charts.html?package=is-finalizationregistry
[codecov-image]: https://codecov.io/gh/inspect-js/is-finalizationregistry/branch/main/graphs/badge.svg
[codecov-url]: https://app.codecov.io/gh/inspect-js/is-finalizationregistry/
[actions-image]: https://img.shields.io/endpoint?url=https://github-actions-badge-u3jn4tfpocch.runkit.sh/inspect-js/is-finalizationregistry
[actions-url]: https://github.com/inspect-js/is-finalizationregistry/actions
inspect-js-is-finalizationregistry-bcac67b/index.d.ts 0000664 0000000 0000000 00000000212 14730207007 0023125 0 ustar 00root root 0000000 0000000 declare function isFinalizationRegistry(value: unknown): value is FinalizationRegistry;
export = isFinalizationRegistry;
inspect-js-is-finalizationregistry-bcac67b/index.js 0000664 0000000 0000000 00000001472 14730207007 0022702 0 ustar 00root root 0000000 0000000 'use strict';
var callBound = require('call-bound');
/** @type {undefined | ((value: ThisParameterType, ...args: Parameters) => ReturnType)} */
var $register = callBound('FinalizationRegistry.prototype.register', true);
/** @type {import('.')} */
module.exports = $register
? function isFinalizationRegistry(value) {
if (!value || typeof value !== 'object') {
return false;
}
try {
// @ts-expect-error TS can't figure out that it's always truthy here
$register(value, {}, null);
return true;
} catch (e) {
return false;
}
}
// @ts-ignore unused var
: function isFinalizationRegistry(value) { // eslint-disable-line no-unused-vars
return false;
};
inspect-js-is-finalizationregistry-bcac67b/package.json 0000664 0000000 0000000 00000004420 14730207007 0023517 0 ustar 00root root 0000000 0000000 {
"name": "is-finalizationregistry",
"version": "1.1.1",
"description": "Is this value a JS FinalizationRegistry? This module works cross-realm/iframe, and despite ES6 @@toStringTag.",
"main": "index.js",
"types": "index.d.ts",
"exports": {
".": "./index.js",
"./package.json": "./package.json"
},
"sideEffects": true,
"scripts": {
"prepack": "npmignore --auto --commentLines=autogenerated",
"prepublishOnly": "safe-publish-latest",
"prepublish": "not-in-publish || npm run prepublishOnly",
"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)\")\"",
"lint": "eslint --ext=.js,.mjs .",
"postlint": "tsc -P . && attw -P",
"pretest": "npm run lint",
"tests-only": "nyc tape 'test/**/*.js'",
"test": "npm run tests-only",
"posttest": "npx npm@'>=10.2' audit --production"
},
"repository": {
"type": "git",
"url": "git+https://github.com/inspect-js/is-finalizationregistry.git"
},
"keywords": [
"weakref",
"finalization",
"finalizationregistry",
"finalization registry"
],
"author": "Jordan Harband ",
"funding": {
"url": "https://github.com/sponsors/ljharb"
},
"license": "MIT",
"bugs": {
"url": "https://github.com/inspect-js/is-finalizationregistry/issues"
},
"homepage": "https://github.com/inspect-js/is-finalizationregistry#readme",
"dependencies": {
"call-bound": "^1.0.3"
},
"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/tape": "^5.7.0",
"auto-changelog": "^2.5.0",
"encoding": "^0.1.13",
"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",
"safe-publish-latest": "^2.0.0",
"tape": "^5.9.0",
"typescript": "next"
},
"auto-changelog": {
"output": "CHANGELOG.md",
"template": "keepachangelog",
"unreleased": false,
"commitLimit": false,
"backfillLimit": false,
"hideCredit": true
},
"publishConfig": {
"ignore": [
".github/workflows"
]
},
"engines": {
"node": ">= 0.4"
}
}
inspect-js-is-finalizationregistry-bcac67b/test/ 0000775 0000000 0000000 00000000000 14730207007 0022210 5 ustar 00root root 0000000 0000000 inspect-js-is-finalizationregistry-bcac67b/test/index.js 0000664 0000000 0000000 00000001641 14730207007 0023657 0 ustar 00root root 0000000 0000000 'use strict';
var test = require('tape');
var inspect = require('object-inspect');
var forEach = require('for-each');
var isFinalizationRegistry = require('..');
test('isFinalizationRegistry', function (t) {
t.equal(typeof isFinalizationRegistry, 'function', 'is a function');
var nonFinalizationRegistries = [undefined, null, true, false, 42, 0, Infinity, NaN, /a/g, function () {}, {}, []];
forEach(nonFinalizationRegistries, function (nonFinalizationRegistry) {
t.equal(isFinalizationRegistry(nonFinalizationRegistry), false, inspect(nonFinalizationRegistry) + ' is not a FinalizationRegistry');
});
t.test('actual FinalizationRegistry instances', { skip: typeof FinalizationRegistry === 'undefined' }, function (st) {
var registry = new FinalizationRegistry(function () {});
st.equal(isFinalizationRegistry(registry), true, inspect(registry) + ' is a FinalizationRegistry');
st.end();
});
t.end();
});
inspect-js-is-finalizationregistry-bcac67b/tsconfig.json 0000664 0000000 0000000 00000000173 14730207007 0023741 0 ustar 00root root 0000000 0000000 {
"extends": "@ljharb/tsconfig",
"compilerOptions": {
"target": "ES2021",
},
"exclude": [
"coverage"
]
}