{"name":"@multiformats/uri-to-multiaddr","version":"10.0.0","description":"Convert a URI to a Multiaddr","author":{"name":"olizilla"},"license":"Apache-2.0 OR MIT","homepage":"https://github.com/multiformats/js-uri-to-multiaddr#readme","repository":{"type":"git","url":"git+https://github.com/multiformats/js-uri-to-multiaddr.git"},"bugs":{"url":"https://github.com/multiformats/js-uri-to-multiaddr/issues"},"publishConfig":{"access":"public","provenance":true},"type":"module","types":"./dist/src/index.d.ts","exports":{".":{"types":"./dist/src/index.d.ts","import":"./dist/src/index.js"}},"release":{"branches":["main"],"plugins":[["@semantic-release/commit-analyzer",{"preset":"conventionalcommits","releaseRules":[{"breaking":true,"release":"major"},{"revert":true,"release":"patch"},{"type":"feat","release":"minor"},{"type":"fix","release":"patch"},{"type":"docs","release":"patch"},{"type":"test","release":"patch"},{"type":"deps","release":"patch"},{"scope":"no-release","release":false}]}],["@semantic-release/release-notes-generator",{"preset":"conventionalcommits","presetConfig":{"types":[{"type":"feat","section":"Features"},{"type":"fix","section":"Bug Fixes"},{"type":"chore","section":"Trivial Changes"},{"type":"docs","section":"Documentation"},{"type":"deps","section":"Dependencies"},{"type":"test","section":"Tests"}]}}],"@semantic-release/changelog","@semantic-release/npm","@semantic-release/github",["@semantic-release/git",{"assets":["CHANGELOG.md","package.json"]}]]},"scripts":{"clean":"aegir clean","lint":"aegir lint","docs":"aegir docs","dep-check":"aegir dep-check","doc-check":"aegir doc-check","generate":"protons src/pb/peer.proto src/pb/tags.proto","build":"aegir build","test":"aegir test","test:chrome":"aegir test -t browser","test:chrome-webworker":"aegir test -t webworker","test:firefox":"aegir test -t browser -- --browser firefox","test:firefox-webworker":"aegir test -t webworker -- --browser firefox","test:node":"aegir test -t node","test:electron-main":"aegir test -t electron-main","release":"aegir release"},"dependencies":{"@multiformats/multiaddr":"^13.0.0","is-ip":"^5.0.0"},"devDependencies":{"aegir":"^47.0.21"},"_id":"@multiformats/uri-to-multiaddr@10.0.0","gitHead":"d996c1d1a5d2ee5a04d98f04dd484ddaa133a6df","_nodeVersion":"22.19.0","_npmVersion":"10.9.3","dist":{"integrity":"sha512-QsmwLmY6iB1wDU1e1wyctqF0eP/2KD1QPLQ+APISuqETbCTSpaq159S/K/ssmWlBpSEkhH0SUfBUgGi014Ttfw==","shasum":"a78f54c2c7be4c58645079104e9d1e08c4508e34","tarball":"http://registry-npm.ywwl.com/@multiformats/uri-to-multiaddr/download/@multiformats/uri-to-multiaddr-10.0.0.tgz","fileCount":10,"unpackedSize":229070,"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@multiformats%2furi-to-multiaddr@10.0.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQCGhhBpbxc3MUauqEkWiwmh3nOQzvNpK4/9LB4RGul6qgIgTtZ1E1jw1xTIKbCArnqNGZsTuMbJYCPkmhIg2LIRAAo="}],"size":62227,"noattachment":false,"key":"/@multiformats/uri-to-multiaddr/-/@multiformats/uri-to-multiaddr-10.0.0.tgz"},"_npmUser":{"name":"achingbrain","email":"alex@achingbrain.net"},"directories":{},"maintainers":[{"name":"daviddias","email":"mail@daviddias.me"},{"name":"vmx","email":"volker.mische@gmail.com"},{"name":"mikeal","email":"mikeal.rogers@gmail.com"},{"name":"hugomrdias","email":"hugomrdias@gmail.com"},{"name":"alanshaw","email":"alan138@gmail.com"},{"name":"achingbrain","email":"alex@achingbrain.net"},{"name":"vascosantos","email":"santos.vasco10@gmail.com"},{"name":"rvagg","email":"r@va.gg"},{"name":"lidel","email":"lidel@lidel.org"},{"name":"npm-service-account-multiformats","email":"npm-service-account+multiformats@ipfs.tech"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/uri-to-multiaddr_10.0.0_1756896765489_0.8841637691649658"},"_hasShrinkwrap":false,"readme":"# @multiformats/uri-to-multiaddr\n\n[![multiformats.io](https://img.shields.io/badge/project-IPFS-blue.svg?style=flat-square)](http://multiformats.io)\n[![codecov](https://img.shields.io/codecov/c/github/multiformats/js-uri-to-multiaddr.svg?style=flat-square)](https://codecov.io/gh/multiformats/js-uri-to-multiaddr)\n[![CI](https://img.shields.io/github/actions/workflow/status/multiformats/js-uri-to-multiaddr/js-test-and-release.yml?branch=main\\&style=flat-square)](https://github.com/multiformats/js-uri-to-multiaddr/actions/workflows/js-test-and-release.yml?query=branch%3Amain)\n\n> Convert a URI to a Multiaddr\n\n# About\n\n<!--\n\n!IMPORTANT!\n\nEverything in this README between \"# About\" and \"# Install\" is automatically\ngenerated and will be overwritten the next time the doc generator is run.\n\nTo make changes to this section, please update the @packageDocumentation section\nof src/index.js or src/index.ts\n\nTo experiment with formatting, please run \"npm run docs\" from the root of this\nrepo and examine the changes made.\n\n-->\n\n```typescript\nimport { uriToMultiaddr } from '@multiformats/uri-to-multiaddr'\n\nconsole.log(uriToMultiaddr('https://protocol.ai'))\n// -> /dns4/protocol.ai/tcp/443/https\n```\n\nDomain names can represent one of\n\n- `/dns4` - domain resolves to an ipv4 address (**default**)\n- `/dns6` - domain resolves to an ipv6 address\n- `/dnsaddr` - domain has a [DNSLink](https://docs.ipfs.io/guides/concepts/dnslink/) TXT record pointing to an IPFS CID\n\nThis library assumes `/dns4` when it finds a domain name in the input string.\nIt makes no attempt query DNS. To override the default assumption, you can pass\nin an options object as the second parameter to override it:\n\n```typescript\nimport { uriToMultiaddr } from '@multiformats/uri-to-multiaddr'\n\nconsole.log(uriToMultiaddr('https://protocol.ai'), { defaultDnsType: 'dns6' })\n// -> /dns6/protocol.ai/tcp/443/https\n```\n\nSee [test.js](./test.js) for the currently supported conversions.\n\n**Note**: `uri-to-multiaddr` will throw if the passed URI:\n\n- is not a valid, according the WHATWG URL spec implementation used.\n- is not supported yet\n\n## Related\n\n- [@multiformats/multiaddr-to-uri](https://github.com/multiformats/js-multiaddr-to-uri) - convert it back again\n\n# Install\n\n```console\n$ npm i @multiformats/uri-to-multiaddr\n```\n\n## Browser `<script>` tag\n\nLoading this module through a script tag will make its exports available as `MultiformatsUriToMultiaddr` in the global namespace.\n\n```html\n<script src=\"https://unpkg.com/@multiformats/uri-to-multiaddr/dist/index.min.js\"></script>\n```\n\n# API Docs\n\n- <https://multiformats.github.io/js-uri-to-multiaddr>\n\n# License\n\nLicensed under either of\n\n- Apache 2.0, ([LICENSE-APACHE](https://github.com/multiformats/js-uri-to-multiaddr/LICENSE-APACHE) / <http://www.apache.org/licenses/LICENSE-2.0>)\n- MIT ([LICENSE-MIT](https://github.com/multiformats/js-uri-to-multiaddr/LICENSE-MIT) / <http://opensource.org/licenses/MIT>)\n\n# Contribution\n\nUnless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.\n","publish_time":1756896765672,"_cnpm_publish_time":1756896765672,"dist-tags":{"latest":"10.0.0"}}