ViewTemplateGenerator class

Generates zfa make-style view templates using ControlledWidget, FragmentBuilder, and SignalBuilder.

final gen = ViewTemplateGenerator(outputDir: 'lib/presentation');
gen.generateView('ProductDetail', useCases: ['product', 'reviews']);

Constructors

ViewTemplateGenerator({required String outputDir})

Properties

hashCode int
The hash code for this object.
no setterinherited
outputDir String
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

generatePresenter(String name, {List<String> useCases = const [], bool preserveIfExists = true}) String
Generate a {name}Presenter that extends DualLayerPresenter, wiring the generated DomainState and scaffolded ViewState together.
generateView(String name, {required List<String> useCases, List<String> uiSignals = const ['isLoading', 'activeTabIndex'], Map<String, String> uiSignalTypes = const {}}) String
Generate a complete view file with ControlledWidget, FragmentBuilder, and SignalBuilder scaffolding.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited