charms-js
Version:
TypeScript SDK for decoding Bitcoin transactions containing Charms data
26 lines (25 loc) • 856 B
TypeScript
/**
* WASM Integration for Charms.js
* Provides a simplified API that uses WASM when available, falls back to current implementation
*/
import { CharmExtractionResult } from './types';
/**
* Initialize WASM module (to be called by consuming applications)
* @param wasm - The loaded WASM module
*/
export declare function initializeWasm(wasm: any): void;
/**
* Check if WASM is available
*/
export declare function isWasmAvailable(): boolean;
/**
* Extract charms using WASM (when available)
* @param txHex - Transaction hex string
* @param txId - Transaction ID
* @returns Standardized CharmExtractionResult
*/
export declare function extractCharmsWithWasm(txHex: string, txId: string, network?: 'mainnet' | 'testnet4'): Promise<CharmExtractionResult>;
/**
* Get WASM module info for debugging
*/
export declare function getWasmInfo(): any;