A flutter state management solution.

Overview

A Flutter State Management solution with dependency injection

Usage

Create your business logic class and place all variables, methods inside it.

import 'package:power_state/power_state.dart';

class CounterController extends PowerController {
  int count = 1;

  increment() {
    count++;
    notifyListeners();
  }
}

Instantiate your class using PowerVault.put(CounterController())

final CounterController controller = PowerVault.put(CounterController());

Then you can use powerBuilder widget in your UI side

 PowerBuilder<CounterController>(
              builder: (countController) {
                return Text(countController.count.toString());
              },
            ),

You can find a Controller that is being used by another page and redirect you to it.

final CounterController countController = PowerVault.find();

You can delete a Controller.

PowerVault.delete<CounterController>();

PowerSelector Widget

PowerSelector allows you to select a specific value listen to. Then when and only when that selected value changes, the widget that returns by the builder method of Selector will rebuild.

PowerSelector<CounterController>(
              <!-- It will listen selectorValue -->
              selector: () => controller.selectorValue,
              builder: (countController) {
                return Text(countController.selectorValue.toString());
              },
 ),

Play with example code

You might also like...

Flutter-minimalist - Flutter Minimalist state management example

Flutter-minimalist - Flutter Minimalist state management example

Flutter Minimalist state management example Because the official Flutter website

Mar 31, 2022

Flutter bloc example - An app for State management using BLoC pattern in Flutter

Flutter bloc example - An app for State management using BLoC pattern in Flutter

Flutter BLoC My first app for State management using BLoC pattern in Flutter Col

Jun 16, 2022

Flutter getx template - A Flutter Template using GetX package for State management, routing and Dependency Injection

Flutter getx template - A Flutter Template using GetX package for State management, routing and Dependency Injection

Flutter GetX Template (GetX, Dio, MVVM) This Flutter Template using GetX package

Aug 27, 2022

Doctor Consultation App in Flutter containing splash screen on boarding screen Routing state management Dash board Bottom navigation Decorated Drawer and Doctors Screen in the last.

Doctor Consultation App in Flutter containing splash screen on boarding screen  Routing  state management Dash board Bottom navigation Decorated Drawer and Doctors Screen in the last.

Online doctor Consultation App UI in Flutter Doctor Consultation App UI in Flutter Visit Website Features State Management Navigation Bar Responsive D

Jan 1, 2023

A project built to learn Flutter state management

Tienda Tienda is a simple product store mobile application. Tienda is a flutter application which was solely built to learn App state and local state

Nov 28, 2021

An easy Flutter state management library

An easy Flutter state management library

EbloX An easy Flutter state management library.It is similar to Bloc, but it uses a lot of annotations and separates business logic from UI through th

Oct 29, 2022

Flutter Task Manager Application Using GetX State Management

Flutter Task Manager Application Using GetX State Management

Flutter Task Manager Application Using GetX State Management flutter_getx_todo A new Flutter project. Getting Started This project is a starting point

Nov 11, 2022
Owner
Masum Billah Sanjid
Masum Billah Sanjid
GetX - one of the most popular state management solution in flutter

GteX Tutorial - Udemy GetX is one of the most popular state management solution in flutter. In addition to state management, GetX provides easy way to

Md. Siam 3 May 18, 2022
A flutter state management solution.

A Flutter State Management solution with dependency injection Usage Create your business logic class and place all variables, methods inside it. impor

Masum Billah Sanjid 5 Dec 15, 2022
Cubit is a lightweight state management solution

Cubit is a lightweight state management solution. It is a subset of the bloc package that does not rely on events and instead uses methods to emit new states.

Felix Angelov 582 Nov 23, 2022
This repo is an example of clean architecture using the GetX state-management solution.

GetX Clean Architecture A Flutter Clean Architecture Using GetX. This repo is forked from: https://github.com/phamdinhduc795397/flutter-getx-clean-arc

Md. Siam 78 Jan 3, 2023
A simple state management solution that combine the power of inherited widget and rxdart

Inherited RxDart is a state management library that combine the power of InheritedWidget and RxDart, a simple and elegant state management solution for apps of any scale

Nguyễn Ngọc Phước 14 Oct 26, 2022
State Persistence - Persist state across app launches. By default this library store state as a local JSON file called `data.json` in the applications data directory. Maintainer: @slightfoot

State Persistence Persist state across app launches. By default this library store state as a local JSON file called data.json in the applications dat

Flutter Community 70 Sep 28, 2022
Practice building basic animations in apps along with managing app state by BLoC State Management, Flutter Slider.

Practice building basic animations in apps along with managing app state by BLoC State Management including: Cubit & Animation Widget, Flutter Slider.

TAD 1 Jun 8, 2022
An extension to the bloc state management library which lets you create State Machine using a declarative API

An extension to the bloc state management library which lets you create State Machine using a declarative API

null 25 Nov 28, 2022
A powerful state machine for MobX management, that can be used in almost any application state.

A powerful state machine for MobX management, which can be used in almost any application state. It has 3 states - loading, success, error - and is pe

Daniel Magri 8 Oct 31, 2022
Shopify Tag and Product Management App using Flutter and Riverpod State Management

Myshopify App A Simple Flutter Application project to get List of Tags, Products and Product Details from shopify https://shopicruit.myshopify.com/adm

Idowu Tomiwa 5 Nov 12, 2022