Skip to content
This repository was archived by the owner on Feb 12, 2024. It is now read-only.
This repository was archived by the owner on Feb 12, 2024. It is now read-only.

Resolve ipns on browser side #1644

Closed
Closed
@mullerivan

Description

@mullerivan

HI there, That is a grate app im working on some test that intent to resolve in client/browser side a static IPNS with something like

<script src="https://unpkg.com/ipfs/dist/index.js"></script>


const node = new Ipfs({
        EXPERIMENTAL: {
            pubsub: true // required, enables pubsub
        },
        repo: 'ipfs-' + Math.random(),
        config: {
            Addresses: {
                Swarm: [
                    '/dns4/ws-star.discovery.libp2p.io/tcp/443/wss/p2p-websocket-star'
                ]
            }
        }
    });
node.once('ready', () => {})

result = node.resolve('/ipns/IPNS-HASH',
node._peerInfo.id,{local:false,recursive=true},
function (err) {console.log(err)})

Any idea how is the proper way to call ipns to resolve an static hash and give me back the last updated hash of the curren file?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions