nexo_cli 0.3.1
nexo_cli: ^0.3.1 copied to clipboard
CLI generator for Nexo-based Clean Architecture in Flutter apps. Scaffolds feature folders with Bloc or Cubit, data/domain layers, and tests.
Changelog #
0.3.1 #
- Migrated to Dart 3.13+ patterns: switch expressions, collection if/for, null-aware elements.
- Replaced
as boolcasts withargResults!.flag()API. - Added strict analysis_options.yaml with 150+ lint rules.
- Fixed all lint warnings and formatting issues.
0.3.0 #
- New
--streamflag: GenerateNexoStreamUseCasewithwatchAll()repository method. - New
--stream-onlyflag: Pure stream use case withoutgetAll(). - New
--paginationflag: GeneratePaginationControllerfor paginated lists. - New
--optimisticflag: Generate cubit withperformOptimistichelper for optimistic updates. - New
--validatorsflag: GenerateNexoValidatorsvalidation in create/update params. - New
--get-by-idflag: GenerateGetByIdUseCasefor fetching single entities. - New
--local-storage <type>flag: Generate real local datasource implementations:hive: Hive box with JSON serializationshared-prefs: SharedPreferences with JSON string storagesecure-storage: FlutterSecureStorage with encrypted storage
- New
--async-cubitflag: GenerateNexoAsyncCubitwithfetch()pattern. - New
nexo fixcommand: Patch freezed 3.x codegen bugs (extraneousfinalmodifier). - Fixed angle brackets in doc comments (
NexoAsyncState<T>,Stream<Result<T>>). - Fixed unused
_repositoryfields in stream and CRUD use case templates. - Fixed unused
nexo_core.dartimport in test templates. - 132 tests passing.
0.2.2 #
- New
--rootflag to customize output directory (default:lib/features). - 91 tests passing.
0.2.1 #
- Fixed: repository template now adds
@Named('prod')on constructor parameter when--mockis enabled (resolves injectable DI ambiguity). - Fixed: repository template now imports mapper and calls
.toDomain()only when--mapperis enabled. - Fixed:
--no-mappermode generatesreturn const []with a TODO comment instead of broken.toDomain()call. - 90 tests passing.
0.2.0 #
- Breaking: cubit is now the default presentation style (was bloc).
- New
--bloc/--cubit/--list-cubitflags for presentation style selection. - New
--presentation-onlyflag for UI-only features. - New
--freezed/--no-freezedflag (default: on). - New
--injectable/--no-injectableflag (default: on). - New
--mapper/--no-mapperflag (default: on). - New
--mock/--no-mockflag (default: on). - New
--get/--create/--update/--deleteflags for CRUD operations. - New
--json '{...}'flag to generate model fields from JSON. - New
--list true/falseflag for list vs single object. - New
--preferencesflag for SharedPreferences wrapper. - New
--extensionsflag for entity extensions. - New
--uiflag for pages and widgets. - Interface-based datasource pattern (
i_remote_*,i_local_*). - Mock datasource generation with environment-conditional DI.
- Request DTOs for create/update operations.
- Domain parameters for use cases.
- Updated templates to match nexo patterns (easycoins, niet_media).
- Added comprehensive documentation (
DOCUMENTATION.md). - Added example features with real generated code.
- 88 tests passing.
0.1.0 #
- Initial release.
featurecommand: scaffold Clean Architecture layout underlib/features/<name>/.- Templates for Bloc or Cubit, repository, use case, remote datasource, entity, and optional layers.
- Flags:
--bloc/--no-bloc,--cubit,--tests,--local,--ui,--dry-run,--overwrite. dart pub global activatesupport vianexo_cliexecutable.