flutter_tex icon indicating copy to clipboard operation
flutter_tex copied to clipboard

Unable to load asset: $key | flutter_tex: ^4.0.3+4

Open Ali-Kheiri opened this issue 2 years ago • 1 comments

I don't know exactly which part this problem refers to, but when I use this widget on a page, I encounter the following error. await ServicesBinding.instance.defaultBinaryMessenger.send('flutter/assets', encoded.buffer.asByteData()); if (asset == null) { throw FlutterError('Unable to load asset: $key'); } return asset; } And in file webView_flutter_plus.dart : body = (await rootBundle.load(path)).buffer.asUint8List();

Ali-Kheiri avatar Sep 10 '22 17:09 Ali-Kheiri

const String _texText = r'''<img src="/assets/images/image.svg"> <br>$$ a^2 = b^2 + c^2 - 2 \, b \, c \cos \alpha $$''';
just add folder assets in yaml and put /assets/images/image.svg OR png

abdelrahman-abied avatar Jan 27 '23 16:01 abdelrahman-abied