How to get asset file on isolate.

214 views
Skip to first unread message

sziky jtk

unread,
Jul 29, 2020, 10:20:20 AM7/29/20
to Flutter Development (flutter-dev)
I already added the WidgetsFlutterBinding.ensureInitialized() before runApp(),but it's still the same. 

This code is a part of isolate, not main .

Souvik Dutta

unread,
Jul 29, 2020, 10:50:24 AM7/29/20
to sziky jtk, Flutter Development (flutter-dev)
Add this line before runApp() in your main function WidgetsFlutterBinding.ensureInitialized();

--
You received this message because you are subscribed to the Google Groups "Flutter Development (flutter-dev)" group.
To unsubscribe from this group and stop receiving emails from it, send an email to flutter-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/flutter-dev/740e4539-4c54-440f-9125-615f4c0eeda5o%40googlegroups.com.

sziky jtk

unread,
Jul 29, 2020, 10:56:08 AM7/29/20
to Flutter Development (flutter-dev)
I did it. but it doesn't change.

Souvik Dutta

unread,
Jul 29, 2020, 12:42:29 PM7/29/20
to sziky jtk, Flutter Development (flutter-dev)
How about loading the assets 1 frame after the initial ui has been completed that is using await before loading the image? I guess this should work without much latency. 

On Wed, Jul 29, 2020, 8:26 PM sziky jtk <flukb...@gmail.com> wrote:
I did it. but it doesn't change.

--
You received this message because you are subscribed to the Google Groups "Flutter Development (flutter-dev)" group.
To unsubscribe from this group and stop receiving emails from it, send an email to flutter-dev...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages