addToCache method
Implementation
Future<void> addToCache(String key, Uint8List imageBytes) async {
final res = await promiseToFutureAsMap(
jsInvokeMethod("addToCache", imageBytes, key),
);
if (res == null) throw Exception("no data recived from js");
if (res["error"] != null) throw Exception(res["error"]);
}