encryptDataBatch
encryptDataBatch(
values: (string|Uint8Array<ArrayBufferLike>)[],address:string):Promise<string[]>
Defined in: src/react/useEncryption.ts:641Â
Batch encrypt multiple values efficiently with a single key lookup. Much faster than calling encryptData for each value individually.
Parameters
| Parameter | Type | Description |
|---|---|---|
|
|
( |
Array of plaintext values to encrypt |
|
|
|
The wallet address associated with the encryption key |
Returns
Promise<string[]>
Array of encrypted values as hex strings
Throws
Error if encryption key is not found in memory
Example
const encrypted = await encryptDataBatch(
["secret1", "secret2", "secret3"],
walletAddress
);Last updated on