future_manager 1.11.0 copy "future_manager: ^1.11.0" to clipboard
future_manager: ^1.11.0 copied to clipboard

ValueNotifier and ValueListenableBuilder but for asynchronous value.

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:future_manager/future_manager.dart';
import 'package:skadi/skadi.dart';

import 'home.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return FutureManagerProvider(
      onFutureManagerError: (error, context) {
        errorLog("On FutureManager error called");
      },
      child: MaterialApp(
        debugShowCheckedModeBanner: false,
        title: 'Future Manager Example',
        theme: ThemeData(
          primarySwatch: Colors.blue,
        ),
        home: MyHomePage(
          dataManager: () => FutureManager(
            reloading: true,
            cacheOption: const ManagerCacheOption.non(),
          ),
        ),
      ),
    );
  }
}
9
likes
140
pub points
68%
popularity

Publisher

verified publisherlynical.com

ValueNotifier and ValueListenableBuilder but for asynchronous value.

Homepage
Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (LICENSE)

Dependencies

flutter

More

Packages that depend on future_manager