Skip to content

Commit

Permalink
fix(blockstore): use simpler block interface in type
Browse files Browse the repository at this point in the history
do not use concrete type for block in the interface definition
  • Loading branch information
hannahhoward committed Apr 8, 2021
1 parent d0ad9a4 commit dd812a6
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/types.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ import type { BigNumber } from 'bignumber.js'

import type CID from 'cids'

import type Block from 'ipld-block'

export type AwaitIterable<T> = Iterable<T> | AsyncIterable<T>
export type Await<T> = Promise<T> | T

Expand Down Expand Up @@ -61,6 +59,11 @@ export interface Stat {
repoSize: BigNumber
}

export interface Block {
cid: CID
data: Uint8Array
}

export interface Blockstore {
open: () => Promise<Void>
/**
Expand Down

0 comments on commit dd812a6

Please sign in to comment.