Skip to content

Refactor/cubit to notifier migration#42

Open
aydinguven-leancode wants to merge 14 commits into
refactor/forms-reworkfrom
refactor/cubit-to-notifier-migration
Open

Refactor/cubit to notifier migration#42
aydinguven-leancode wants to merge 14 commits into
refactor/forms-reworkfrom
refactor/cubit-to-notifier-migration

Conversation

@aydinguven-leancode

Copy link
Copy Markdown

LMG-394

  • Migration from Cubit to a Value Notifier based state management
  • Dropped dependencies: flutter_bloc, rx_dart, flutter_hooks, equatable`
  • Name changes for relevant classes
  • Relevant changes on tests and example project

LMG-404

  • Partially modified Readme.md and Changelog.md files about the above migration
  • Introduced Migration.md file
  • Added a few more examples as well as short descriptions to each example page

aydinguven-leancode and others added 4 commits June 19, 2026 09:57
…nagement

Migrated from Cubit (Bloc) to value notifier.
Removed dependencies: flutter_bloc, rx_dart, equatable,
Changes are reflected on examples
Changes are reflected on tests
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Comment thread example/lib/controllers/focusable_text_field_controller.dart Outdated
Comment thread example/lib/controllers/focusable_text_field_controller.dart
Comment thread EXAMPLES.md Outdated
Comment thread EXAMPLES.md Outdated
Comment thread EXAMPLES.md Outdated
FieldBuilder<String, ValidationError>(
field: context.read<SignupController>().email,
builder: (context, state) => TextFormField(
controller: context.read<SignupController>().email.textController,

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We already passed the field controller, why fetch it again? Please just add the field controller itself into the builder callback params.

Comment thread EXAMPLES.md Outdated
Comment thread CHANGELOG.md Outdated
Comment thread pubspec.yaml Outdated
Comment thread lib/src/field/field_controller.dart Outdated
Comment thread lib/src/form_group/form_group_controller.dart Outdated
Comment thread lib/src/field/field_controller.dart Outdated
Comment thread lib/src/field/field_controller.dart Outdated
Comment thread example/lib/screens/delivery_form.dart Outdated
Comment thread example/lib/screens/optimized_rendering_form.dart Outdated
Comment thread example/pubspec.yaml
Comment thread lib/src/form_group/form_group_controller.dart Outdated
Comment thread EXAMPLES.md
Comment thread example/test/screens/simple_form_test.dart
Comment thread lib/src/form_group/form_group_controller.dart Outdated
Removed unnecessary //ignore commands
Reverted version change on leancode_lint in example project
Added debugLabel
Removed the bits about previous versions from EXAMPLES.md
Added `child` param to fieldBuilder class to fully support builder closures
Various minor fixes
Examples modified
FormGroupState is renamed into FormState
Examples and tests modified accordingly
Comment on lines +306 to +308
/// **Maintainer note:** when adding a new field below, you MUST also add it
/// to both [operator ==] and [hashCode] at the bottom of the class, otherwise
/// the new field is silently invisible to dedup and structural comparisons.

@PiotrRogulski PiotrRogulski Jun 23, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This note shouldn't be part of the dartdoc – it shouldn't show up in hover popups or in the generated docs:

Image

(in AdvancedFormState too)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants