{"name":"isurl","version":"5.0.0","keywords":["uri","url","whatwg"],"author":{"url":"https://svachon.com","name":"Steven Vachon","email":"contact@svachon.com"},"license":"MIT","_id":"isurl@5.0.0","maintainers":[{"name":"stevenvachon","email":"contact@svachon.com"}],"homepage":"https://github.com/stevenvachon/isurl#readme","bugs":{"url":"https://github.com/stevenvachon/isurl/issues"},"dist":{"shasum":"a70e5080c43a23398189af369a3b40fcfe35bacf","tarball":"http://registry-npm.ywwl.com/isurl/download/isurl-5.0.0.tgz","fileCount":15,"integrity":"sha512-g9vIg3aJxAc5mkkVGZiap46/yiNI3okkaXEm5FdOfN2z3ub45dSqp2MGYT280gynw7Gz/vp9CsakCfvMz5QcFg==","signatures":[{"sig":"MEQCIEAW5o8k6pJM89C2XpKcD1EDeXyh/zNKn+TGaCoAyt5RAiAccp2k1ltNAp47uVE6cRl/KVQjX+bXeUrJi1qaOCHwmA==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"sig":"MEQCIC4hs11b6V5KMOsNH+esRcqNvcsmHCVmnWeu6dq7JE2+AiA4otbqFeDP9TnHSy7Dixw9fLplVqlHY1SX2bwVPo+WHg==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":9478,"size":3726,"noattachment":false,"key":"/isurl/-/isurl-5.0.0.tgz"},"type":"module","engines":{"node":">= 22"},"exports":{".":"./dist/isURL.js","./lenient":"./dist/isURLLenient.js"},"gitHead":"a8f0309e37576541a388b3d559e12c9d767ee6f0","scripts":{"test":"npm run test:watch -- --reporter=verbose --run","build":"npm run build:spellcheck && npm run build:lint && npm run build:typecheck:supplemental && npm run build:compile && npm run build:filesize","build:lint":"prettier --check '**/*.{config.js,json,md,ts}' '!coverage/**' '!dist/**'","test:watch":"vitest dev --coverage --coverage.exclude=src/*.test.ts --coverage.include=src/*.ts --coverage.reporter=html --coverage.reporter=lcov --coverage.reporter=text","build:compile":"tsc -p tsconfig.build.json","build:filesize":"rollup dist/isURL.js --format umd --name isURL -p @rollup/plugin-node-resolve -p @rollup/plugin-commonjs | terser --compress 'passes=3' --mangle | gzip-size","prepublishOnly":"npm run build && npm test","build:spellcheck":"cspell '**/*.{config.js,json,md,ts}' '!coverage/**' '!dist/**' '!node_modules/**' --no-progress","build:typecheck:supplemental":"tsc --project tsconfig.check.json"},"_npmUser":{"name":"stevenvachon","email":"contact@svachon.com"},"repository":{"url":"git+https://github.com/stevenvachon/isurl.git","type":"git"},"_npmVersion":"11.12.1","description":"Determine whether a value is a URL instance.","directories":{},"_nodeVersion":"24.15.0","dependencies":{"is-object":"^1.0.2","has-tostringtag":"^1.0.2","is-urlsearchparams":"^2.0.0-rc"},"_hasShrinkwrap":false,"devDependencies":{"cspell":"^10.0.1","rollup":"^4.62.4","terser":"^5.50.0","vitest":"^4.1.10","prettier":"^3.9.6","typescript":"^7.0.2","whatwg-url":"^17.1.0","@types/node":"^26.2.0","gzip-size-cli":"^5.1.0","incomplete-url":"^5.0.0","@types/is-object":"^1.0.5","@types/whatwg-url":"^13.0.0","incomplete-symbol":"^2.0.0","@vitest/coverage-v8":"^4.1.10","@rollup/plugin-commonjs":"^29.0.3","@rollup/plugin-node-resolve":"^16.0.3"},"_npmOperationalInternal":{"tmp":"tmp/isurl_5.0.0_1787774956810_0.8555196818681905","host":"s3://npm-registry-packages-npm-production"},"readme":"# isurl [![NPM Version][npm-image]][npm-url] ![File Size][filesize-image] ![Build Status][ghactions-image] [![Coverage Status][codecov-image]][codecov-url]\n\n> Determine whether a value is a [`URL`](https://mdn.io/URL) instance.\n\nWorks cross-realm/iframe and despite `Symbol.toStringTag`.\n\n> [!NOTE]\n>\n> If you need to support older versions of Node.js (going back to `8.x`), use `4.x` of this package.\n\n## Install\n\n```shell\nnpm install isurl\n```\n\n## Usage\n\n### Strict\n\nThe standard.\n\n```js\nimport isURL from 'isurl';\n\nisURL('http://domain/'); //-> false\nisURL(new URL('http://domain/')); //-> true\n```\n\n### Lenient\n\nAcceptance can be extended to incomplete `URL` implementations that lack `origin`, `searchParams` and `toJSON` properties (which is common with web browsers from 2021):\n\n```js\nimport isURL from 'isurl/lenient';\n\nconsole.log(url.searchParams); //-> undefined\n\nisURL(url); //-> true\n```\n\n[npm-image]: https://img.shields.io/npm/v/isurl\n[npm-url]: https://npmjs.com/package/isurl\n[filesize-image]: https://img.shields.io/badge/bundle-865B%20gzipped-blue.svg\n[ghactions-image]: https://img.shields.io/github/actions/workflow/status/stevenvachon/isurl/test.yml\n[codecov-image]: https://img.shields.io/codecov/c/github/stevenvachon/isurl\n[codecov-url]: https://app.codecov.io/github/stevenvachon/isurl\n","publish_time":1787774956922,"_cnpm_publish_time":1787774956922,"dist-tags":{"latest":"5.0.0","rc":"5.0.0-rc"}}