FLUTTER ECOSYSTEM

aligorithm/easy_loader

在 Flutter 中处理简单全屏加载器的最简单方法。用 Dart 编写。

easy_loader 项目封面
Stars
5
Forks
3
最近推送(UTC)
2021年12月2日
项目状态
未归档
Aliyu Yisa GitHub avatar
GITHUB User

Aliyu Yisa ↗

Learn, experiment, build!

University of SalfordGreater Manchester
语言DartHTMLSwiftKotlinObjective-C

技术话题

此仓库发布的插件

使用的依赖

依赖清单 2 项
  • flutter{"sdk":"flutter"}
  • flutter_test开发依赖{"sdk":"flutter"}

原始 README

以下为英文项目原文快照,最新内容请访问 GitHub。

展开 / 收起项目 README

EasyLoader

The easiest way to handle a simple full screen loader in Flutter. Written in Dart. Fully customizable.

Screenshot

Getting Started

Add this to your package's pubspec.yaml file

dependencies:
  easy_loader: ^1.0.3

Usage

Next, you just have to import the package using:

import 'package:easy_loader/easy_loader.dart';

Then wrap your body within a Stack and place the EasyLoader() widget at the end of the Stack

  Widget build(BuildContext context) {
    return Scaffold(
      //// Wrap your body in a stack
      body: Stack(
        children: <Widget>[
          Center(
            child: Text("Lorem Ipsum"),
          ),
          //// Put the loader widget at the end of the stack. You can set it to appear based on a boolean. E.g. a loading flag.
          EasyLoader(image: AssetImage('assets/loading.png'),)
        ],
      ),
    );
  }

All done! You can customize other things like the icon size, background color, icon color and the animation by passing the values into the constructor.