BrownfieldReusePatterns extension

on

Methods

ensureLibraryComponentReuse({required String page, required BrownfieldPatternTarget anchor, required String libraryProjectId, required String componentName, required String componentKey, required Map<String, DslType> params, Map<String, Object?> arguments = const <String, Object?>{}, String? insertedName, bool after = true}) → void

Available on App, provided by the BrownfieldReusePatterns extension

Inserts a linked library component beside an existing anchor.
ensureProjectComponentReuse({required String page, required BrownfieldPatternTarget anchor, required String componentName, required Map<String, DslType> params, Map<String, Object?> arguments = const <String, Object?>{}, String? insertedName, bool after = true}) → void

Available on App, provided by the BrownfieldReusePatterns extension

Inserts an existing shared project component beside an existing anchor.
ensureThemeColorReuse({required String page, required BrownfieldPatternTarget target, required String tokenQuery, DslReuseResolutionPolicy policy = DslReuseResolutionPolicy.closestMatch}) → void

Available on App, provided by the BrownfieldReusePatterns extension

Replaces a literal color choice with a resolved theme token.
extractRepeatedWidgetsToComponent({required String componentName, required List<BrownfieldPatternOccurrence> occurrences}) → void

Available on App, provided by the BrownfieldReusePatterns extension

Extracts repeated existing widgets into a shared project component and replaces each occurrence with a component instance.