Files
pezkuwi-api/packages/bizinikiwi-bindings/dist/esm/codecs/scale/Hex.mjs
T
Kurdistan Tech Ministry 31467f90d4 feat: add PAPI rebrand packages
- @pezkuwi/papi-utils (rebrand of @polkadot-api/utils)
- @pezkuwi/bizinikiwi-bindings (rebrand of @polkadot-api/substrate-bindings)
- @pezkuwi/metadata-builders (rebrand of @polkadot-api/metadata-builders)
- @pezkuwi/merkleize-metadata (rebrand of @polkadot-api/merkleize-metadata)

All @polkadot-api references replaced with @pezkuwi equivalents.
2026-01-22 15:40:12 +03:00

18 lines
465 B
JavaScript

import { fromHex, toHex } from '@pezkuwi/papi-utils';
import { createCodec, Bytes } from 'scale-ts';
const enc$1 = (nBytes) => {
const _enc = Bytes.enc(nBytes);
return (value) => _enc(fromHex(value));
};
const dec$1 = (nBytes) => {
const _dec = Bytes.dec(nBytes);
return (value) => toHex(_dec(value));
};
const Hex = (nBytes) => createCodec(enc$1(nBytes), dec$1(nBytes));
Hex.enc = enc$1;
Hex.dec = dec$1;
export { Hex };
//# sourceMappingURL=Hex.mjs.map