wasm fixes

This commit is contained in:
Christien Rioux 2023-10-14 20:18:37 -04:00
parent a363bb0462
commit e40975104e
10 changed files with 90 additions and 43 deletions

View file

@ -246,6 +246,11 @@ const int messageStreamClose = 8;
// Interface factory for high level Veilid API
Veilid getVeilid() => VeilidFFI(_dylib);
// Uint8List marshaling
Uint8List convertUint8ListFromJson(dynamic json) =>
base64UrlNoPadDecode(json as String);
dynamic convertUint8ListToJson(Uint8List data) => base64UrlNoPadEncode(data);
// Parse handle async returns
Future<T> processFuturePlain<T>(Future<dynamic> future) async =>
future.then((value) {