@fruitsjs/util
Version:
Useful utilities and tools for building Fruits Eco-Blockchain applications
14 lines (12 loc) • 533 B
text/typescript
import {convertByteArrayToString} from './convertByteArrayToString';
import {convertHexStringToByteArray} from './convertHexStringToByteArray';
/**
* Converts a Hexadecimally encoded string into String
* Inverse function [[convertStringToHexString]]
* @param hex The Hex string to be converted
* @return {string} The string represented by the Hex String
* @module util
*/
export const convertHexStringToString = (hex: string): string => {
return convertByteArrayToString(convertHexStringToByteArray(hex));
};