mirror of
https://github.com/pezkuwichain/pezkuwi-common.git
synced 2026-04-22 23:08:01 +00:00
chore: update to version 14.0.11 and align website URLs
This commit is contained in:
Vendored
+22
@@ -0,0 +1,22 @@
|
||||
import type { U8aLike } from '../types.js';
|
||||
import { BN } from '../bn/index.js';
|
||||
/**
|
||||
* @name compactFromU8a
|
||||
* @description Retrives the offset and encoded length from a compact-prefixed value
|
||||
* @example
|
||||
* <BR>
|
||||
*
|
||||
* ```javascript
|
||||
* import { compactFromU8a } from '@pezkuwi/util';
|
||||
*
|
||||
* const [offset, length] = compactFromU8a(new Uint8Array([254, 255, 3, 0]));
|
||||
*
|
||||
* console.log('value offset=', offset, 'length=', length); // 4, 0xffff
|
||||
* ```
|
||||
*/
|
||||
export declare function compactFromU8a(input: U8aLike): [number, BN];
|
||||
/**
|
||||
* @name compactFromU8aLim
|
||||
* @description A limited version of [[compactFromU8a]], accepting only Uint8Array inputs for values <= 48 bits
|
||||
*/
|
||||
export declare function compactFromU8aLim(u8a: Uint8Array): [number, number];
|
||||
Reference in New Issue
Block a user