Skip to content

Latest commit

 

History

History
46 lines (31 loc) · 1.5 KB

README.md

File metadata and controls

46 lines (31 loc) · 1.5 KB

Flutter Bloc Implementation

This project demonstrates a basic implementation of state management in Flutter using the Bloc and Cubit pattern. The application features a simple counter and a to-do list, showcasing the use of both Cubit and Bloc for managing state.

Features

  • Counter Functionality: Increment and decrement the counter value using Bloc.
  • To-Do List Management: Add tasks to a to-do list using Cubit.
  • State Management with Bloc and Cubit: Examples of both state management approaches.
  • Clean and Modular Code: Well-structured codebase for easy understanding and extension.

Project Structure

  • bloc: Contains the CounterBloc for managing the counter state.
  • cubit: Contains the TodoCubit for managing the list of to-dos.
  • models: Defines the Todo model.
  • screens: Contains the main UI components and pages.

Getting Started

  1. Clone the repository:

    git clone https://github.com/yourusername/flutter_bloc_implementation.git
    cd flutter_bloc_implementation
  2. Install dependencies:

    flutter pub get
  3. Run the app:

    flutter run

Usage

  • Counter: Use the increment and decrement buttons to change the counter value. The initial value is set to 1903.
  • To-Do List: Add new tasks to the to-do list using the input field and the add button.

Contributions

Contributions are welcome! Please open an issue or submit a pull request for any improvements or additions.