UNPKG

@bitcoinerlab/secp256k1

Version:

A library for performing elliptic curve operations on the secp256k1 curve. It is designed to integrate into the BitcoinJS & BitcoinerLAB ecosystems and uses the audited noble-secp256k1 library. It is compatible with environments that do not support WASM,

10 lines (7 loc) 196 B
import { Buffer } from "buffer"; export function fromHex(data) { return new Uint8Array(Buffer.from(data, "hex")); } export function toHex(data) { return Buffer.from(data).toString("hex"); }