convertString function

Uint8List convertString(
  1. String str, {
  2. bool useDartEncode = true,
})

Implementation

Uint8List convertString(String str, {bool useDartEncode = true}) {
  return isHex(str)
      ? hexToU8a(str)
      : stringToU8a(str, useDartEncode: useDartEncode);
}