✨A clean and lightweight loading/toast widget for Flutter, easy to use without context, support iOS、Android and Web

Last update: Jun 22, 2022

Flutter EasyLoading

pub package pub points popularity likes license stars

English | 简体中文

Live Preview

👉 https://nslog11.github.io/flutter_easyloading

Installing

Add this to your package's pubspec.yaml file:

dependencies:
  flutter_easyloading: ^3.0.3

Import

import 'package:flutter_easyloading/flutter_easyloading.dart';

How to use

First, initialize EasyLoading in your MaterialApp/CupertinoApp:

class MyApp extends StatelessWidget {
  // This widget is the root of your application.
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter EasyLoading',
      theme: ThemeData(
        primarySwatch: Colors.blue,
      ),
      home: MyHomePage(title: 'Flutter EasyLoading'),
      builder: EasyLoading.init(),
    );
  }
}

Then, enjoy yourself:

EasyLoading.show(status: 'loading...');

EasyLoading.showProgress(0.3, status: 'downloading...');

EasyLoading.showSuccess('Great Success!');

EasyLoading.showError('Failed with Error');

EasyLoading.showInfo('Useful Information.');

EasyLoading.showToast('Toast');

EasyLoading.dismiss();

Add loading status callback

EasyLoading.addStatusCallback((status) {
  print('EasyLoading Status $status');
});

Remove loading status callback(s)

EasyLoading.removeCallback(statusCallback);

EasyLoading.removeAllCallbacks();

Customize

❗️ Note:

  • textColorindicatorColorprogressColorbackgroundColor only used for EasyLoadingStyle.custom.

  • maskColor only used for EasyLoadingMaskType.custom.

/// loading style, default [EasyLoadingStyle.dark].
EasyLoadingStyle loadingStyle;

/// loading indicator type, default [EasyLoadingIndicatorType.fadingCircle].
EasyLoadingIndicatorType indicatorType;

/// loading mask type, default [EasyLoadingMaskType.none].
EasyLoadingMaskType maskType;

/// toast position, default [EasyLoadingToastPosition.center].
EasyLoadingToastPosition toastPosition;

/// loading animationStyle, default [EasyLoadingAnimationStyle.opacity].
EasyLoadingAnimationStyle animationStyle;

/// loading custom animation, default null.
EasyLoadingAnimation customAnimation;

/// textAlign of status, default [TextAlign.center].
TextAlign textAlign;

/// textStyle of status, default null.
TextStyle textStyle;

/// content padding of loading.
EdgeInsets contentPadding;

/// padding of [status].
EdgeInsets textPadding;

/// size of indicator, default 40.0.
double indicatorSize;

/// radius of loading, default 5.0.
double radius;

/// fontSize of loading, default 15.0.
double fontSize;

/// width of progress indicator, default 2.0.
double progressWidth;

/// width of indicator, default 4.0, only used for [EasyLoadingIndicatorType.ring, EasyLoadingIndicatorType.dualRing].
double lineWidth;

/// display duration of [showSuccess] [showError] [showInfo], default 2000ms.
Duration displayDuration;

/// animation duration of indicator, default 200ms.
Duration animationDuration;

/// color of loading status, only used for [EasyLoadingStyle.custom].
Color textColor;

/// color of loading indicator, only used for [EasyLoadingStyle.custom].
Color indicatorColor;

/// progress color of loading, only used for [EasyLoadingStyle.custom].
Color progressColor;

/// background color of loading, only used for [EasyLoadingStyle.custom].
Color backgroundColor;

/// mask color of loading, only used for [EasyLoadingMaskType.custom].
Color maskColor;

/// should allow user interactions while loading is displayed.
bool userInteractions;

/// should dismiss on user tap.
bool dismissOnTap;

/// indicator widget of loading
Widget indicatorWidget;

/// success widget of loading
Widget successWidget;

/// error widget of loading
Widget errorWidget;

/// info widget of loading
Widget infoWidget;

Because of EasyLoading is a singleton, so you can custom loading style any where like this:

EasyLoading.instance
  ..displayDuration = const Duration(milliseconds: 2000)
  ..indicatorType = EasyLoadingIndicatorType.fadingCircle
  ..loadingStyle = EasyLoadingStyle.dark
  ..indicatorSize = 45.0
  ..radius = 10.0
  ..progressColor = Colors.yellow
  ..backgroundColor = Colors.green
  ..indicatorColor = Colors.yellow
  ..textColor = Colors.yellow
  ..maskColor = Colors.blue.withOpacity(0.5)
  ..userInteractions = true
  ..dismissOnTap = false
  ..customAnimation = CustomAnimation();

More indicatorType can see in 👉 flutter_spinkit showcase

Custom Animation

example: 👉 Custom Animation

Todo

  • add progress indicator

  • add custom animation

Changelog

CHANGELOG

License

MIT License

❤️ ❤️ ❤️

Thanks to flutter_spinkit ❤️

Supported by JetBrains Open Source

GitHub

https://github.com/huangjianke/flutter_easyloading
Comments
  • 1. Exception when selecting text inside a FormField

    Steps to reproduce:

    1. Add TextField widget to the app (like this).
    2. Open the app and type some text in the field
    3. Try and select the text (to copy it for example)

    Log

    I/flutter (30736): ══╡ EXCEPTION CAUGHT BY WIDGETS LIBRARY ╞═══════════════════════════════════════════════════════════ I/flutter (30736): The following assertion was thrown building I/flutter (30736): _OverlayEntry-[LabeledGlobalKey<_OverlayEntryState>#0c596](dirty, state: _OverlayEntryState#026a0): I/flutter (30736): No MediaQuery widget found. I/flutter (30736): _OverlayEntry widgets require a MediaQuery widget ancestor. I/flutter (30736): The specific widget that could not find a MediaQuery ancestor was: I/flutter (30736): _OverlayEntry-[LabeledGlobalKey<_OverlayEntryState>#0c596] I/flutter (30736): The ownership chain for the affected widget is: I/flutter (30736): "_OverlayEntry-[LabeledGlobalKey<_OverlayEntryState>#0c596] ← Stack ← _Theatre ← Overlay ← I/flutter (30736): Directionality ← FlutterEasyLoading ← MyApp ← [root]" I/flutter (30736): Typically, the MediaQuery widget is introduced by the MaterialApp or WidgetsApp widget at the top of I/flutter (30736): your application widget tree. I/flutter (30736): I/flutter (30736): The relevant error-causing widget was: I/flutter (30736): Overlay file:///D:/Projects/flutter_easyloading/lib/src/widgets/loading.dart:35:14 I/flutter (30736): I/flutter (30736): When the exception was thrown, this was the stack: I/flutter (30736): #0 debugCheckHasMediaQuery. (package:flutter/src/widgets/debug.dart:219:7) I/flutter (30736): #1 debugCheckHasMediaQuery (package:flutter/src/widgets/debug.dart:231:4) I/flutter (30736): #2 _MaterialTextSelectionControls.buildToolbar (package:flutter/src/material/text_selection.dart:148:12) I/flutter (30736): #3 TextSelectionOverlay._buildToolbar (package:flutter/src/widgets/text_selection.dart:556:34) I/flutter (30736): #4 _OverlayEntryState.build (package:flutter/src/widgets/overlay.dart:169:25) I/flutter (30736): #5 StatefulElement.build (package:flutter/src/widgets/framework.dart:4440:27) I/flutter (30736): #6 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4329:15) I/flutter (30736): #7 Element.rebuild (package:flutter/src/widgets/framework.dart:4053:5) I/flutter (30736): #8 ComponentElement._firstBuild (package:flutter/src/widgets/framework.dart:4312:5) I/flutter (30736): #9 StatefulElement._firstBuild (package:flutter/src/widgets/framework.dart:4487:11) I/flutter (30736): #10 ComponentElement.mount (package:flutter/src/widgets/framework.dart:4307:5) I/flutter (30736): #11 Element.inflateWidget (package:flutter/src/widgets/framework.dart:3297:14) I/flutter (30736): #12 Element.updateChild (package:flutter/src/widgets/framework.dart:3091:12) I/flutter (30736): #13 RenderObjectElement.updateChildren (package:flutter/src/widgets/framework.dart:5326:32) I/flutter (30736): #14 MultiChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:5694:17) I/flutter (30736): #15 Element.updateChild (package:flutter/src/widgets/framework.dart:3080:15) I/flutter (30736): #16 _TheatreElement.update (package:flutter/src/widgets/overlay.dart:615:16) I/flutter (30736): #17 Element.updateChild (package:flutter/src/widgets/framework.dart:3080:15) I/flutter (30736): #18 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:4349:16) I/flutter (30736): #19 Element.rebuild (package:flutter/src/widgets/framework.dart:4053:5) I/flutter (30736): #20 BuildOwner.buildScope (package:flutter/src/widgets/framework.dart:2532:33) I/flutter (30736): #21 WidgetsBinding.drawFrame (package:flutter/src/widgets/binding.dart:796:20) I/flutter (30736): #22 RendererBinding._handlePersistentFrameCallback (package:flutter/src/rendering/binding.dart:283:5) I/flutter (30736): #23 SchedulerBinding._invokeFrameCallback (package:flutter/src/scheduler/binding.dart:1108:15) I/flutter (30736): #24 SchedulerBinding.handleDrawFrame (package:flutter/src/scheduler/binding.dart:1047:9) I/flutter (30736): #25 SchedulerBinding._handleDrawFrame (package:flutter/src/scheduler/binding.dart:963:5) I/flutter (30736): #29 _invoke (dart:ui/hooks.dart:260:10) I/flutter (30736): #30 _drawFrame (dart:ui/hooks.dart:218:3) I/flutter (30736): (elided 3 frames from package dart:async) I/flutter (30736): I/flutter (30736): ════════════════════════════════════════════════════════════════════════════════════════════════════ I/flutter (30736): Another exception was thrown: No MediaQuery widget found.

    Reviewed by ice-j at 2020-01-25 21:10
  • 2. '_overlay != null' error

    use EasyLoading.show(status: "loading..."); Error!

    error stack: [VERBOSE-2:ui_dart_state.cc(157)] Unhandled Exception: 'package:flutter/src/widgets/overlay.dart': Failed assertion: line 132 pos 12: '_overlay != null': is not true. #0 _AssertionError._doThrowNew (dart:core-patch/errors_patch.dart:42:39) #1 _AssertionError._throwNew (dart:core-patch/errors_patch.dart:38:5) #2 OverlayEntry.remove (package:flutter/src/widgets/overlay.dart:132:12) #3 EasyLoading._remove (package:flutter_easyloading/src/easy_loading.dart:353:34) #4 EasyLoading._show (package:flutter_easyloading/src/easy_loading.dart:323:5) #5 EasyLoading.show (package:flutter_easyloading/src/easy_loading.dart:165:20) #6 OrderAction.getOrderDetail (package:novo/action/order_action.dart:156:17) #7 _OrderDetailState.initState (package:novo/page/order/order_detail.dart:66:19) #8 StatefulElement._firstBuild (package:flutter/src/widgets/framework.dart:4640:58) #9 ComponentElement.mount (package:flutter/src/widgets/framework.dart:4476:5) #10 Element.inflat<…>

    this place: void _remove() { _getInstance().overlayEntry?.remove(); _getInstance()._overlayEntry = null; _getInstance()._key = null; _getInstance()._progress = null; _getInstance()._progressKey = null; }

    Reviewed by genius1212 at 2020-03-17 01:32
  • 3. SpinKitPouringHourglass name changed

    Describe the bug Try correcting the name to the name of an existing method, or defining a method named 'SpinKitPouringHourglass'. _indicator = SpinKitPouringHourglass( ^^^^^^^^^^^^^^^^^^^^^^^

    FAILURE: Build failed with an exception.

    The dependent flutter_spinkit package upgraded and the Class name SpinKitPouringHourglass changed to SpinKitPouringHourGlass , thus build error occures

    The related link is here

    Reviewed by idemirel at 2021-08-28 12:43
  • 4. dismissOnTap: true , has no effect

    Describe the bug flutter_easyloading: ^3.0.0

    EasyLoading.showToast(mesaj, toastPosition: EasyLoadingToastPosition.center, dismissOnTap: true, duration: Duration(seconds: 5));

    but toast is disappearing without requesting any tap.

    Flutter/Dart info please run flutter doctor then put it here. Doctor summary (to see all details, run flutter doctor -v): [√] Flutter (Channel beta, 2.0.1, on Microsoft Windows [Version 10.0.19041.867], locale en-US) [√] Android toolchain - develop for Android devices (Android SDK version 30.0.0) [√] Chrome - develop for the web [√] Visual Studio - develop for Windows (Visual Studio Community 2019 16.9.1)
    [√] Android Studio (version 4.1.0) [√] VS Code (version 1.54.3) [√] Connected device (3 available)

    • No issues found!

    Screenshots If applicable, add screenshots to help explain your problem.

    Reviewed by guyulmaz at 2021-03-18 15:08
  • 5. Unsupported operation: Platform._operatingSystem

    Describe the bug when I use this plugin on flutter web, it crashes, the bug description is "Unsupported operation: Platform._operatingSystem The relevant error-causing widget was: ", it says "flutter_easyloading-2.2.2/lib/src/widgets/loading.dart:62:14", the code as follow

    @override
      Widget build(BuildContext context) {
        return Material(
          child: Overlay(
            initialEntries: [
              EasyLoadingOverlayEntry(
                builder: (BuildContext context) => widget.child,
              ),
              _overlayEntry,
            ],
          ),
        );
      }
    

    Screenshots

    Reviewed by YueYongDev at 2021-01-08 02:46
  • 6. 执行了几次dismiss后再执行dissmiss无效了

    上传图片时需要显示loading, 使用了EasyLoading.show(status: '上传头像中…', dismissOnTap: false);,使用try{}catch(){}来捕捉,最终都会EasyLoadin.dismiss()掉,但是在无网状态下上传了两次消失之后再点击上传,这个loading框就再也不消失了,但是通过输出确认代码是走到了EasyLoading.dismiss()这一行的,想知道是啥原因

    Reviewed by cherrybiu at 2020-11-13 10:26
  • 7. Dialog中使用show不出来,没有报错

    之前在Dialog中可以正常使用,因为我是点击按钮直接弹窗,没有异步操作,但是现在我需要使用Dio框架请求数据回来后再弹窗,这时无论我怎么改,穷尽我能想象到的原因都无法解决,然后改用1.3.0版后可以show出来了,但是弹窗的遮罩层却变成不透明的了,像是给Dialog嵌了一层Material,并且之前的一些可以正常使用的非Dialog场景又出了问题,show不出来! 刚转flutter没多久,求大佬解救

    Reviewed by liangtian123 at 2020-09-28 14:22
  • 8. Looking up a deactivated widget's ancestor is unsafe.

    您好,异常信息如下:

    ════════ Exception caught by gesture ═══════════════════════════════════════════════════════════════
    The following assertion was thrown while handling a gesture:
    Looking up a deactivated widget's ancestor is unsafe.
    
    At this point the state of the widget's element tree is no longer stable.
    
    To safely refer to a widget's ancestor in its dispose() method, save a reference to the ancestor by calling dependOnInheritedWidgetOfExactType() in the widget's didChangeDependencies() method.
    
    When the exception was thrown, this was the stack: 
    #0      Element._debugCheckStateIsActiveForAncestorLookup.<anonymous closure> (package:flutter/src/widgets/framework.dart:3781:9)
    #1      Element._debugCheckStateIsActiveForAncestorLookup (package:flutter/src/widgets/framework.dart:3795:6)
    #2      Element.findAncestorStateOfType (package:flutter/src/widgets/framework.dart:3914:12)
    #3      Overlay.of (package:flutter/src/widgets/overlay.dart:256:19)
    #4      EasyLoading._show (package:flutter_easyloading/src/easy_loading.dart:338:13)
    ...
    Handler: "onTap"
    Recognizer: TapGestureRecognizer#4bbd8
      debugOwner: GestureDetector
      state: ready
      won arena
      finalPosition: Offset(265.3, 280.0)
      finalLocalPosition: Offset(235.3, 7.0)
      button: 1
      sent tap down
    ════════════════════════════════════════════════════════════════════════════════════════════════════
    W/IInputConnectionWrapper( 8770): getTextBeforeCursor on inactive InputConnection
    W/IInputConnectionWrapper( 8770): getTextBeforeCursor on inactive InputConnection
    W/IInputConnectionWrapper( 8770): getTextBeforeCursor on inactive InputConnection
    W/IInputConnectionWrapper( 8770): getTextBeforeCursor on inactive InputConnection
    W/HiTouch_PressGestureDetector( 8770): Touch pointer move a lot. The moving distance of X is:20.0, limit is:60The moving distance of Y is:63.0, limit is:60
    

    以下是我部分代码:

    import 'package:flutter/material.dart';
    import 'package:flutter_easyloading/flutter_easyloading.dart'; 
    
    class UploadArticlePage extends StatelessWidget {
      @override
      Widget build(BuildContext context) {
        return new MaterialApp(
          debugShowCheckedModeBanner: false,
          home: _UploadArticlePage(),
        );
      }
    }
    
    class _UploadArticlePage extends StatefulWidget {
      @override
      State<StatefulWidget> createState() => _UploadArticleState();
    }
    
    class _UploadArticleState extends State<_UploadArticlePage> {
    
      FocusNode _focusNode = FocusNode();
      TextEditingController _controller;
    
      @override
      void initState() {
        super.initState();
        _controller = new TextEditingController();
      }
    
      @override
      void dispose() { 
        _controller.dispose();
        super.dispose();
      }
    
      @override
      Widget build(BuildContext context) {
        Widget uploadButtonSection = new Padding(
          padding: EdgeInsets.only(top: 20),
          child: new RawMaterialButton(
              elevation: 2,
              shape: new RoundedRectangleBorder(
                borderRadius: BorderRadius.all(Radius.circular(6.0)),
              ),
              padding: EdgeInsets.all(8),
              splashColor: Colors.white70,
              fillColor: Colors.orange,
              child: new Text(
                '上传',
                textAlign: TextAlign.center,
                style: new TextStyle(
                  color: Colors.white,
                  fontSize: 18,
                ),
              ),
              onPressed: () {
                String uploadUrl = _controller.text.toString();
                if (uploadUrl.length == 0) {
                  hintToast('上传地址不能为空,快去复制吧');
                  return;
                }
                if (!uploadUrl.contains('mp.weixin.qq.com')) {
                  hintToast('仅支持上传微信公众号链接!');
                  return;
                }
                _postUploadArticle(uploadUrl);
              }),
        );
    
        return Scaffold(
            body: new GestureDetector(
          behavior: HitTestBehavior.translucent,
          onTap: () async {
            FocusScope.of(context).requestFocus(_focusNode);
          },
          child: new Container(
            alignment: Alignment.center,
            margin: EdgeInsets.all(30),
            child: new ListView(
              children: <Widget>[
                uploadButtonSection, 
              ],
            ),
          ),
        ));
      }
    
      void _postUploadArticle(String uploadUrl) {
        EasyLoading.show();
        HttpManager().post(
            url: uploadArticle,
            params: {
              'timestamp': currentTimeMillis(),
              'token': _userToken,
              'url': uploadUrl
            },
            successCallback: (date) {
              EasyLoading.dismiss();
              hintToast('上传成功~');
              _controller.clear();
            },
            errorCallback: (HttpError err) {
              EasyLoading.dismiss();
              hintToast(err.message);
              _controller.clear();
            },
            tag: requestTag);
      }
    }
    
    
    Reviewed by HLQ-Struggle at 2020-05-25 08:32
  • 9. overlayEntry should not be null

    Describe the bug I receive an error from flutter [VERBOSE-2:ui_dart_state.cc(177)] Unhandled Exception: 'package:flutter_easyloading/src/easy_loading.dart': Failed assertion: line 428 pos 7: 'overlayEntry != null': overlayEntry should not be null

    Flutter/Dart info please run flutter doctor then put it here.

    Screenshots If applicable, add screenshots to help explain your problem.

    Reviewed by stoppiNeobiz at 2021-01-07 09:50
  • 10. dismiss异步

    dismiss这个方法异步操作真的让我很费解,弄成异步的问题,我描述下:

    • 某种场景,一个页面提交表单后(提交完后调用dismiss),立马跳转到下个页面,下个页面初始化时需要调用一堆接口,此时开启加载动画,同样是异步操作,此时上个页面异步dismiss此时就会调用,会关闭当前页面的加载动画。

    我看了下dismiss里面异步代码,也没啥异步取消操作,就算你搞成异步也没关系,至少要把返回类型搞成Future啊,至少能让我await dismiss结束,而不是让他在某个不确定的时间,跑出来执行不符合预期的效果。

    Reviewed by xdd666t at 2020-11-10 02:22
  • 11. TextField Error when you double tap or longpress while using flutter_easyloading

    Describe the bug With the new flutter update 1.17.0, anytime I double-tap or long-press the TextField, I get an error

    ERROR MESSAGE ═══════ Exception caught by widgets library ═══════════════════

    The following assertion was thrown building _OverlayEntryWidget-[LabeledGlobalKey<_OverlayEntryWidgetState>#8973d](dirty, state: _OverlayEntryWidgetState#3a398): No MediaQuery widget found.

    _OverlayEntryWidget widgets require a MediaQuery widget ancestor. The specific widget that could not find a MediaQuery ancestor was: _OverlayEntryWidget-[LabeledGlobalKey<_OverlayEntryWidgetState>#8973d] dirty state: _OverlayEntryWidgetState#3a398 The ownership chain for the affected widget is: "_OverlayEntryWidget-[LabeledGlobalKey<_OverlayEntryWidgetState>#8973d] ← _Theatre ← Overlay ← Directionality ← FlutterEasyLoading ← MyApp ← [root]"

    Typically, the MediaQuery widget is introduced by the MaterialApp or WidgetsApp widget at the top of your application widget tree.

    The relevant error-causing widget was FlutterEasyLoading lib\main.dart:34 When the exception was thrown, this was the stack #0 debugCheckHasMediaQuery. package:flutter/…/widgets/debug.dart:215 #1 debugCheckHasMediaQuery package:flutter/…/widgets/debug.dart:227 #2 _MaterialTextSelectionControls.buildToolbar package:flutter/…/material/text_selection.dart:645 #3 TextSelectionOverlay._buildToolbar package:flutter/…/widgets/text_selection.dart:556 #4 _OverlayEntryWidgetState.build package:flutter/…/widgets/overlay.dart:177 ... ══════════════════════════════════════════════════════════════

    ═══════ Exception caught by widgets library ════════════════════════

    No MediaQuery widget found. The relevant error-causing widget was FlutterEasyLoading lib\main.dart:34 ══════════════════════════════════════════════════════════════

    ════════ Exception caught by widgets library ══════════════════════════

    No MediaQuery widget found. The relevant error-causing widget was FlutterEasyLoading lib\main.dart:34 ══════════════════════════════════════════════════════════════

    ════════ Exception caught by widgets library ═════════════════════════════

    No MediaQuery widget found. The relevant error-causing widget was FlutterEasyLoading lib\main.dart:34 ═══════════════════════════════════════════════════════════

    This is my code structure

     @override
      Widget build(BuildContext context) {
        return FlutterEasyLoading(
          child: ChangeNotifierProvider<StateManagerHelper>(
            create: (context) => StateManagerHelper(),
            child: CustomMaterial(),
          ),
        );
      }
    
    

    Flutter/Dart info [email protected] MINGW64 ~/VSC/FLUTTER/truthx (master) $ flutter doctor Doctor summary (to see all details, run flutter doctor -v): [√] Flutter (Channel stable, v1.17.0, on Microsoft Windows [Version 10.0.17763.973], locale en-US)

    [√] Android toolchain - develop for Android devices (Android SDK version 29.0.3) [√] Android Studio (version 3.6) [√] VS Code (version 1.45.0) [√] Connected device (1 available)

    • No issues found!

    Screenshots If applicable, add screenshots to help explain your problem.

    WhatsApp Image 2020-05-11 at 10 22 10 AM

    Reviewed by Emex4gman at 2020-05-11 09:27
  • 12. Show message with duration

    Describe the bug A clear and concise description of what the bug is.

    Informing the duration in the message, it is not respecting the time, it seems that the time is 2 seconds and closes the message. So you should respect the time that was informed. For the message to be in the correct time, I'm having to put it in the future.delay

    await EasyLoading.showSuccess('Download!', duration: const Duration(seconds: 10));

        await Future.delayed(const Duration(seconds: 10));
    
    Reviewed by SouMeiApp at 2022-06-15 14:14
  • 13. 可否支持动态传入BuildContext

    flutter_easyloading 这个插件用起来很方便,感谢作者的付出!

    可否动态传入BuildContext,实现嵌套子路由限定区域内加载提示信息

    最近碰到一个问题,在使用flutter开发windows下客户端,用到了嵌套路由来实现互不干涉的分屏导航,希望能够在嵌套子路由下面加载 提示信息(也就是在界面的某个特定区域加载提示信息,而不是整个窗口),但是目前 flutter_easyloading 只能在全局 MaterialApp 里面初始化,使用全局的BuildContext,嵌套路由分屏模式下所有的提示只能加载在根路由界面,也就是全局界面

    Reviewed by yuhaya at 2022-06-11 14:26
  • 14. Reset to default settings

    Problem

    As EasyLoading is a singleton, when we use it in many situations with different configurations, they overlap and affect the visuals of the widget.

    Feature Request

    • A reset function to replace all configuration values to the default values.
    Reviewed by OutdatedGuy at 2022-06-05 21:12
  • 15. Error when writing tests for methods that contain EasyLoading.

    When writing a Unit Test for a method i have that has EasyLoading.showToast() being called in it.

    I get the following error: 'package:flutter_easyloading/src/easy_loading.dart': Failed assertion: line 425 pos 7: 'overlayEntry != null': You should call EasyLoading.init() in your MaterialApp

    I tried instantiating the MaterialApp in the test and calling EasyLoading.init() but that didn't work.

    flutter_easyloading: ^3.0.5

    Reviewed by yassinsameh at 2022-05-31 10:30

Related

Shimmer loading - A Flutter project to show how to add shimmer loading animation
Shimmer loading - A Flutter project to show how to add shimmer loading animation

shimmer_loading A Flutter project to show how to add shimmer loading animation.

Feb 6, 2022
Android loading animations
Android  loading animations

Android-SpinKit Android loading animations(I wrote a android edition according SpinKit) Demo Apk Preview Gradle Dependency dependencies { implement

Jun 24, 2022
A flutter package which contains a collection of some cool and beautiful effects; support android and ios
A flutter package which contains a collection of some cool and beautiful effects; support android and ios

flutter effects A flutter package which contains a collection of some cool and beautiful effects; support android and ios . Screenshot type support ch

Jun 21, 2022
This repository demonstrates use of various widgets in flutter and tricks to create beautiful UI elements in flutter for Android and IOS
This repository demonstrates use of various widgets in flutter and tricks to create beautiful UI elements in flutter for Android and IOS

AwesomeFlutterUI The purpose of this repository is to demonstrate the use of different widgets and tricks in flutter and how to use them in your proje

May 20, 2022
Flutter ListView and GridView that shows Loading Widgets before the real data is loaded.
Flutter ListView and GridView that shows Loading Widgets before the real data is loaded.

loadinglistview This package provide an easy way to show loading indicator(Widget) in a listview or a gridview while the app is still fetching the rea

Dec 8, 2021
Help you to build pull-down refresh and pull-up loading in the simplest way.
Help you to build pull-down refresh and pull-up loading in the simplest way.

frefresh Help you to build pull-down refresh and pull-up loading in the simplest way. Although unprecedented simplicity, but the effect is amazing. It

Jun 15, 2022
✨ A collection of loading indicators animated with flutter. Heavily Inspired by http://tobiasahlin.com/spinkit.
✨ A collection of loading indicators animated with flutter. Heavily Inspired by http://tobiasahlin.com/spinkit.

✨ Flutter Spinkit A collection of loading indicators animated with flutter. Heavily inspired by @tobiasahlin's SpinKit. ?? Installing dependencies:

Jun 27, 2022
Loading Animation With Flutter

Flutter Loading Animation loading.ista.mp4 A new Flutter project. Getting Started This project is a starting point for a Flutter application. A few re

Mar 30, 2022
Lazy Loading Flutter Plugin
Lazy Loading Flutter Plugin

flutter_placeholder_textlines A simple plugin to generate placeholder lines that emulates text in a UI, useful for displaying placeholder content whil

Apr 12, 2022
A Flutter package with a selection of simple yet very customizable set of loading animations.
A Flutter package with a selection of simple yet very customizable set of loading animations.

Flutter Loading Animations A simple yet very customizable set of loading animations for Flutter projects. Installation Add the following to your pubsp

May 31, 2022
A Flutter library for loading skeletons

TODO: Put a short description of the package here that helps potential users know whether this package might be useful for them. Features TODO: List w

Jan 6, 2022
A collection of awesome flutter loading animation
A collection of awesome flutter loading animation

loading_indicator_view A collection of awesome flutter loading animation Demo Usage loading_indicator_view: ^1.1.0 Animation types Type Type Type Typ

May 15, 2022
A collection of loading indicators animated with CSS

SpinKit Simple loading spinners animated with CSS. See demo. SpinKit only uses (transform and opacity) CSS animations to create smooth and easily cust

Jun 30, 2022
A collection of awesome loading animations
A collection of awesome loading animations

NVActivityIndicatorView ⚠️ Check out LoaderUI (ready to use with Swift Package Mananger supported) for SwiftUI implementation of this. ?? Introduction

Jun 21, 2022
Delightful, performance-focused pure css loading animations.

Loaders.css Delightful and performance-focused pure css loading animations. What is this? See the demo A collection of loading animations written enti

Jun 28, 2022
A simple custom loading indicator package.
A simple custom loading indicator package.

custom_loading_indicator A Flutter package to customise the loading indicators with your organisation's logo. Let's say you're a dentist and your app

Aug 10, 2020
Loading times are unavoidable in application development. From a user experience (UX) perspective

loading A new Flutter project. Getting Started This project is a starting point for a Flutter application. A few resources to get you started if this

Feb 12, 2022
Flexible and easy to use page transitions.
Flexible and easy to use page transitions.

flutter_villains What are heroes without villains? (Profile image from: https://unsplash.com/photos/pAs4IM6OGWI) Check out the article. What are villa

May 29, 2022
A customizable and easy to use UI widgets to help develop apps faster
A customizable and easy to use UI widgets to help develop apps faster

Lenore UI Beautiful, customizable and easy to use UI widgets to help me (or maybe you) develop my (or maybe your) apps faster. This is my personal pac

Dec 5, 2021