Skip to content

Commit b741399

Browse files
committed
Formatting
1 parent d0845f0 commit b741399

File tree

1 file changed

+24
-26
lines changed

1 file changed

+24
-26
lines changed

src/index.d.ts

Lines changed: 24 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,15 @@
11
declare module "@orbitdb/core" {
22
import type { HeliaLibp2p } from "helia";
3-
import type { Libp2p, PeerId, PrivateKey, ServiceMap } from "@libp2p/interface";
3+
import type {
4+
Libp2p,
5+
PeerId,
6+
PrivateKey,
7+
ServiceMap,
8+
} from "@libp2p/interface";
49
import type { TypedEmitter } from "tiny-typed-emitter";
510
import type { ByteView, CID } from "multiformats";
611

7-
export function createOrbitDB<
8-
T extends ServiceMap = ServiceMap,
9-
>(args: {
12+
export function createOrbitDB<T extends ServiceMap = ServiceMap>(args: {
1013
ipfs: HeliaLibp2p<Libp2p<T>>;
1114
id?: string;
1215
identity?: Identity;
@@ -36,22 +39,21 @@ declare module "@orbitdb/core" {
3639
referencesCount: number;
3740
}>;
3841

39-
type CreateDatabaseOptions<T extends ServiceMap = ServiceMap> =
40-
{
41-
ipfs: HeliaLibp2p<Libp2p<T>>;
42-
identity?: Identity;
43-
address: string;
44-
name?: string;
45-
access?: AccessController;
46-
directory?: string;
47-
meta?: MetaData;
48-
headsStorage?: Storage;
49-
entryStorage?: Storage;
50-
indexStorage?: Storage;
51-
referencesCount?: number;
52-
syncAutomatically?: boolean;
53-
onUpdate?: (log: Log, entry: LogEntry) => void;
54-
};
42+
type CreateDatabaseOptions<T extends ServiceMap = ServiceMap> = {
43+
ipfs: HeliaLibp2p<Libp2p<T>>;
44+
identity?: Identity;
45+
address: string;
46+
name?: string;
47+
access?: AccessController;
48+
directory?: string;
49+
meta?: MetaData;
50+
headsStorage?: Storage;
51+
entryStorage?: Storage;
52+
indexStorage?: Storage;
53+
referencesCount?: number;
54+
syncAutomatically?: boolean;
55+
onUpdate?: (log: Log, entry: LogEntry) => void;
56+
};
5557

5658
export type BaseDatabase = {
5759
address: string;
@@ -252,9 +254,7 @@ declare module "@orbitdb/core" {
252254
}
253255
>;
254256

255-
export function Identities<
256-
T extends ServiceMap = ServiceMap,
257-
>(args: {
257+
export function Identities<T extends ServiceMap = ServiceMap>(args: {
258258
keystore?: KeyStoreType;
259259
path?: string;
260260
storage?: Storage;
@@ -296,9 +296,7 @@ declare module "@orbitdb/core" {
296296
put: (hash: string, data: unknown) => Promise<void>; // Todo: check if DagCborEncodable is appropriate here
297297
get: (hash: string) => Promise<ByteView<unknown>>;
298298
};
299-
export function IPFSBlockStorage<
300-
T extends ServiceMap = ServiceMap,
301-
>(args: {
299+
export function IPFSBlockStorage<T extends ServiceMap = ServiceMap>(args: {
302300
ipfs: HeliaLibp2p<Libp2p<T>>;
303301
pin?: boolean;
304302
timeout?: number;

0 commit comments

Comments
 (0)