Skip to content

Commit

Permalink
Add wrapper code
Browse files Browse the repository at this point in the history
  • Loading branch information
keichan34 committed Jan 5, 2025
1 parent 6d5a618 commit 55b396f
Show file tree
Hide file tree
Showing 9 changed files with 634 additions and 8 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ index.node
npm-debug.log*cargo.log
cross.log
cargo.log
dist
8 changes: 8 additions & 0 deletions index.node.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
/// An opaque type representing a native context.
export type Context = unknown;

export function new_ctx(): Context;
export function db_add(ctx: Context, label: string, data: Uint8Array): undefined;
export function stream_next(ctx: Context): Promise<{value: any} | {done: true}>;
export function stream_write(ctx: Context, data: Uint8Array): undefined;
export function stream_close(ctx: Context): undefined;
Loading

0 comments on commit 55b396f

Please sign in to comment.