File tree Expand file tree Collapse file tree 1 file changed +21
-1
lines changed
Expand file tree Collapse file tree 1 file changed +21
-1
lines changed Original file line number Diff line number Diff line change 1- # ipfs-race
1+ # IPFS Race
2+ [ ![ NPM] ( https://img.shields.io/npm/v/ipfs-race.svg )] ( https://www.npmjs.com/package/ipfs-race )
3+ [ ![ NPM] ( https://img.shields.io/npm/dt/ipfs-race.svg )] ( https://www.npmjs.com/package/ipfs-race )
4+ [ ![ GITHUB] ( https://img.shields.io/github/issues/Frame-One-Software/ipfs-race.svg )] ( https://github.com/Frame-One-Software/ipfs-race/issues )
5+
6+ Resolve an IPFS path using multiple gateways and methods to get data the fastest.
7+
8+ ``` bash
9+ npm i ipfs-race
10+ ```
11+
12+ ``` typescript
13+ import {resolve } from " ipfs-race" ;
14+
15+ resolve (" QmaiJczLW9X1Gk7rQH7CgYCuquLZMbdWB6hhqznDBoqdLE" )
16+ .then (({response , urlResolvedFrom }) => {
17+ console .log (" received data first from: " , urlResolvedFrom );
18+ console .log (" data: " , await response .json ());
19+ })
20+ .catch (console .error );
21+ ```
You can’t perform that action at this time.
0 commit comments