mirror of
https://codeberg.org/demostf/edit.git
synced 2026-06-03 20:04:06 +02:00
js bindings
This commit is contained in:
parent
842a01e52d
commit
beb9bf3aa2
18 changed files with 7985 additions and 6186 deletions
14
js/index.ts
Normal file
14
js/index.ts
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
export interface EditOptions {
|
||||
unlock_pov: boolean,
|
||||
cut?: TickRange,
|
||||
}
|
||||
|
||||
export interface TickRange {
|
||||
from: number,
|
||||
to: number,
|
||||
}
|
||||
|
||||
export async function edit(bytes: Uint8Array, options: EditOptions): Promise<Uint8Array> {
|
||||
let m = await import("../pkg/index.js");
|
||||
return m.edit(bytes, options);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue