*update dist
This commit is contained in:
parent
aad02e4901
commit
fe9045cf82
|
@ -1,13 +1,14 @@
|
|||
import { Client } from "@lumeweb/libkernel-universal";
|
||||
import { CatOptions, LsOptions, StatOptions } from "@helia/unixfs";
|
||||
interface AbortableGenerator {
|
||||
abort: () => void;
|
||||
iterable: AsyncGenerator<object>;
|
||||
}
|
||||
export declare class IPFSClient extends Client {
|
||||
ready(): Promise<any>;
|
||||
stat(cid: string): Promise<any>;
|
||||
ls(cid: string): AbortableGenerator;
|
||||
cat(cid: string): AbortableGenerator;
|
||||
stat(cid: string, options?: Partial<StatOptions>): Promise<any>;
|
||||
ls(cid: string, options?: Partial<LsOptions>): AbortableGenerator;
|
||||
cat(cid: string, options?: Partial<CatOptions>): AbortableGenerator;
|
||||
ipns(cid: string): Promise<string>;
|
||||
activePeers(): Promise<number>;
|
||||
private connectModuleGenerator;
|
||||
|
|
|
@ -1 +1 @@
|
|||
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAW,MAAM,8BAA8B,CAAC;AAG/D,UAAU,kBAAkB;IAC1B,KAAK,EAAE,MAAM,IAAI,CAAC;IAClB,QAAQ,EAAE,cAAc,CAAC,MAAM,CAAC,CAAC;CAClC;AAED,qBAAa,UAAW,SAAQ,MAAM;IACvB,KAAK;IAIL,IAAI,CAAC,GAAG,EAAE,MAAM;IAItB,EAAE,CAAC,GAAG,EAAE,MAAM,GAAG,kBAAkB;IAInC,GAAG,CAAC,GAAG,EAAE,MAAM,GAAG,kBAAkB;IAI9B,IAAI,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAIlC,WAAW,IAAI,OAAO,CAAC,MAAM,CAAC;IAI3C,OAAO,CAAC,sBAAsB;CAgC/B;AAED,eAAO,MAAM,YAAY,8BAGxB,CAAC"}
|
||||
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAW,MAAM,8BAA8B,CAAC;AAE/D,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAEnE,UAAU,kBAAkB;IAC1B,KAAK,EAAE,MAAM,IAAI,CAAC;IAClB,QAAQ,EAAE,cAAc,CAAC,MAAM,CAAC,CAAC;CAClC;AAED,qBAAa,UAAW,SAAQ,MAAM;IACvB,KAAK;IAIL,IAAI,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC;IAItD,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,SAAS,CAAC,GAAG,kBAAkB;IAIjE,GAAG,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,UAAU,CAAC,GAAG,kBAAkB;IAI7D,IAAI,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAIlC,WAAW,IAAI,OAAO,CAAC,MAAM,CAAC;IAI3C,OAAO,CAAC,sBAAsB;CAgC/B;AAED,eAAO,MAAM,YAAY,8BAGxB,CAAC"}
|
|
@ -4,14 +4,14 @@ export class IPFSClient extends Client {
|
|||
async ready() {
|
||||
return this.callModuleReturn("ready");
|
||||
}
|
||||
async stat(cid) {
|
||||
return this.callModuleReturn("stat");
|
||||
async stat(cid, options) {
|
||||
return this.callModuleReturn("stat", { options });
|
||||
}
|
||||
ls(cid) {
|
||||
return this.connectModuleGenerator("ls", { cid });
|
||||
ls(cid, options) {
|
||||
return this.connectModuleGenerator("ls", { cid, options });
|
||||
}
|
||||
cat(cid) {
|
||||
return this.connectModuleGenerator("cat", { cid });
|
||||
cat(cid, options) {
|
||||
return this.connectModuleGenerator("cat", { cid, options });
|
||||
}
|
||||
async ipns(cid) {
|
||||
return this.callModuleReturn("ipnsResolve");
|
||||
|
|
Loading…
Reference in New Issue