can't use it
li-xunhuan opened this issue · comments
李寻欢 commented
E/flutter ( 6877): [ERROR:flutter/lib/ui/ui_dart_state.cc(157)] Unhandled Exception: Bad state: No element
E/flutter ( 6877): #0 Iterable.first (dart:core/iterable.dart:520:7)
E/flutter ( 6877): #1 _showToast (package:flui/widgets/toast.dart:186:45)
E/flutter ( 6877): #2 FLToast.showInfo (package:flui/widgets/toast.dart:164:7)
E/flutter ( 6877): #3 FLToast.info (package:flui/widgets/toast.dart:158:46)
E/flutter ( 6877): #4 _LoginPageState._getAccessTokenHandle (package:whale/pages/login/login_page.dart:169:15)
E/flutter ( 6877): <asynchronous suspension>
E/flutter ( 6877): #5 _LoginPageState._buildSignIn.<anonymous closure> (package:whale/pages/login/login_page.dart:407:32)
E/flutter ( 6877): #6 GestureRecognizer.invokeCallback (package:flutter/src/gestures/recognizer.dart:182:24)
E/flutter ( 6877): #7 TapGestureRecognizer.handleTapUp (package:flutter/src/gestures/tap.dart:486:11)
E/flutter ( 6877): #8 BaseTapGestureRecognizer._checkUp (package:flutter/src/gestures/tap.dart:264:5)
E/flutter ( 6877): #9 BaseTapGestureRecognizer.handlePrimaryPointer (package:flutter/src/gestures/tap.dart:199:7)
E/flutter ( 6877): #10 PrimaryPointerGestureRecognizer.handleEvent (package:flutter/src/gestures/recognizer.dart:467:9)
E/flutter ( 6877): #11 PointerRouter._dispatch (package:flutter/src/gestures/pointer_router.dart:76:12)
E/flutter ( 6877): #12 PointerRouter._dispatchEventToRoutes.<anonymous closure> (package:flutter/src/gestures/pointer_router.dart:117:9)
E/flutter ( 6877): #13 _LinkedHashMapMixin.forEach (dart:collection-patch/compact_hash.dart:379:8)
E/flutter ( 6877): #14 PointerRouter._dispatchEventToRoutes (package:flutter/src/gestures/pointer_router.dart:115:18)
E/flutter ( 6877): #15 PointerRouter.route (package:flutter/src/gestures/pointer_router.dart:101:7)
E/flutter ( 6877): #16 GestureBinding.handleEvent (package:flutter/src/gestures/binding.dart:218:19)
E/flutter ( 6877): #17 GestureBinding.dispatchEvent (package:flutter/src/gestures/binding.dart:198:22)
E/flutter ( 6877): #18 GestureBinding._handlePointerEvent (package:flutter/src/gestures/binding.dart:156:7)
E/flutter ( 6877): #19 GestureBinding._flushPointerEventQueue (package:flutter/src/gestures/binding.dart:102:7)
E/flutter ( 6877): #20 GestureBinding._handlePointerDataPacket (package:flutter/src/gestures/binding.dart:86:7)
E/flutter ( 6877): #21 _rootRunUnary (dart:async/zone.dart:1138:13)
E/flutter ( 6877): #22 _CustomZone.runUnary (dart:async/zone.dart:1031:19)
E/flutter ( 6877): #23 _CustomZone.runUnaryGuarded (dart:async/zone.dart:933:7)
E/flutter ( 6877): #24 _invoke1 (dart:ui/hooks.dart:273:10)
E/flutter ( 6877): #25 _dispatchPointerDataPacket (dart:ui/hooks.dart:182:5)
Hanran commented
你好,请问你有添加 FLToastProvider吗?
李寻欢 commented
木有!!
Hanran commented
木有!!
添加下应该就 ok 了.
doc: https://www.flui.xin/widgets/toast.html#fltoastprovider