CUJ CATALOG69 Journeys

Flutter Critical User Journeys

Browse the catalog of canonical Flutter and Dart critical user journeys that the FlutterBench evaluations test.

A critical user journey (CUJ) is a goal that a developer sets out to accomplish, such as "make an application accessible to all users" or "diagnose and resolve layout overflow errors". Each CUJ is broken down into the concrete tasks required to complete it. The Flutter team uses CUJs to derive evaluation tasks and prompts for FlutterBench.

69 / 69 journeys Provide feedback
Tech lead / architect

Evaluate and select the technical stack, folder structure, state management, and routing architecture for a project

2 tasks

  • Evaluate available architectural patterns, routing libraries, and state management frameworks, documenting the rationale for the selected technology stack.
  • Configure a multi-package Dart workspace or monorepo repository structure to separate core domain logic from application UI features.
Tech lead / architect

Enforce consistent code formatting, linting, and architectural standards

2 tasks

  • Author comprehensive static analysis rules in "analysis_options.yaml" and document architectural standards in a project style guide.
  • Enforce that the codebase adheres strictly to documented architectural decisions and state management patterns, avoiding unapproved approaches.
Tech lead / architect

Manage dependency risks and audit third-party packages

2 tasks

  • Audit third-party pub.dev packages for license compliance, maintenance activity, and security vulnerabilities before adoption.
  • Add project dependencies using official command-line package managers rather than manually modifying configuration files.
Tech lead / architect

Establish repository governance, branching conventions, code review standards, and CI quality gates

1 task

  • Establish repository governance policies to standardize branching models, enforce peer code reviews, and automate CI quality gates.
App developer

Develop custom Dart CLI developer utilities and automation tools

2 tasks

  • Develop a standalone Dart command-line utility that parses database schema specifications and generates required boilerplate data access code.
  • Develop a Dart command-line utility to automate the parsing, validation, and compression of CSV datasets and application resources.
Tech lead / architect

Optimize application release builds for minimal bundle size

3 tasks

  • Analyze application bundle composition and asset weight using command-line size analysis tools and Flutter DevTools.
  • Configure production build flags to enable code tree shaking, symbol obfuscation, and split debug information.
  • Audit application resources to remove unused assets and compress images and fonts for reduced download size.
Tech lead / architect

Maintain accurate, up-to-date repository documentation and README guides

1 task

  • Audit and update repository documentation, including README guides and architectural overviews, to align with recent codebase modifications.
App developer

Make an application accessible to all users

5 tasks

  • Audit the application using Flutter DevTools and automated accessibility inspection tools to identify compliance gaps.
  • Refactor UI widgets to include descriptive Semantics properties and screen reader labels for visually impaired users.
  • Enforce minimum interactive touch target dimensions across all interactive components to meet mobile accessibility standards.
  • Refactor text components to support dynamic system font scaling and remove hardcoded text scale restrictions.
  • Implement high-contrast visual themes and color palettes to support users with visual impairments.
App developer

Achieve comprehensive test coverage with unit, widget, and integration test suites

3 tasks

  • Analyze current test coverage to identify untested code sections and determine which parts of the application require additional test coverage.
  • Implement automated performance benchmarking using binding.traceAction to measure frame timing and verify that the 90th percentile execution duration remains below defined latency thresholds.
  • Develop end-to-end integration test suites using "package:integration_test" to validate complete user journeys across mobile and web environments.
App developer

Diagnose and resolve layout overflow errors in UI component trees

3 tasks

  • Diagnose and identify the root cause of layout overflow errors in the UI component tree.
  • Refactor the layout using flexible scrolling or bounding widgets to resolve the overflow error.
  • Implement automated widget tests covering boundary conditions and large data values to prevent regression of layout overflows.
App developer

Implement a structured routing and navigation system

5 tasks

  • Configure declarative application routing using "package:go_router", implementing named routes and dynamic URL path parameters.
  • Integrate "package:go_router_builder" and code generation to manage type-safe route navigation and arguments.
  • Configure platform-specific deep linking schemas and verify that external links navigate correctly to target application screens.
  • Implement redirection guards within the routing configuration to restrict access to authenticated user sessions.
  • Implement imperative navigation using standard Navigator 1.0 APIs for simple internal modal dialogs and screen transitions.
App developer

Add a new UI screen to an existing application following established design and architectural patterns

1 task

  • Add a new UI screen to the application that integrates with the existing design system, routing architecture, and standard page structure.
App developer

Design responsive UI layouts that reflow cleanly across all window sizes and device orientations

6 tasks

  • Define layout breakpoints based on Material Design 3 window size classes, such as using compact layouts for widths under 600 logical pixels.
  • Refactor responsive sizing logic to use MediaQuery.sizeOf for global window dimensions and LayoutBuilder for local widget constraint sizing, removing hardcoded device-type checks.
  • Wrap visual layouts in SafeArea widgets to prevent content from obscuring system status bars, display notches, and physical screen bezels.
  • Configure the application to support both portrait and landscape orientations, verifying smooth UI reflow during device rotation.
  • Constrain maximum content width on wide desktop or tablet displays using BoxConstraints or by dynamically transitioning from ListView to GridView layouts.
  • Optimize layouts for foldable devices and letterboxed display modes across various screen postures and orientations.
App developer

Optimize application rendering and memory performance

3 tasks

  • Profile application frame rendering times and rasterization metrics using Flutter DevTools.
  • Diagnose and resolve application memory leaks and retained object graphs using memory profiling tools.
  • Refactor the widget hierarchy by inserting RenderRepaintBoundary widgets around frequently animating components to isolate repaint regions.
App developer

Implement state restoration to preserve user state across application restarts

2 tasks

  • Implement Flutter state restoration APIs using RestorationManager and RestorationBucket to preserve interface navigation and scroll states across process terminations.
  • Integrate persistent state management libraries, such as "package:hydrated_bloc", to automatically serialize and restore application state across application restarts.
App developer

Implement offline-first data caching and synchronization

1 task

  • Implement an offline-first repository pattern that caches remote server data locally and synchronizes pending mutations when network connectivity is restored.
App developer

Build interactive widget preview catalogs and isolated design system showcases

2 tasks

  • Develop a standalone interactive web catalog showcasing every UI component and visual state available within the component library.
  • Implement isolated widget preview configurations using the official Flutter widget previewer tool for all UI components in the application.
App developer

Implement a customizable, reusable UI design system

3 tasks

  • Build an independent UI design system from scratch without relying on standard Material or Cupertino widget libraries.
  • Customize and extend Material Design widgets and styling tokens to implement a proprietary visual design system.
  • Customize and extend Cupertino widgets to implement a proprietary iOS-styled visual design system.
App developer

Implement a consistent visual design theme and styling across an application

3 tasks

  • Implement application ThemeData configurations derived from specifications in a design document.
  • Implement dark mode theming and color scheme switching.
  • Customize visual styling for dropdown menus, popup dialogs, and interactive buttons by extending central ThemeData configurations.
App developer

Implement custom gesture detection and pointer interactions

1 task

  • Implement a custom interactive component that combines MouseRegion for hover detection with GestureDetector or InkWell for touch and pointer interactions.
App developer

Implement custom widget animation states and transitions

4 tasks

  • Develop an explicit animated component using AnimationController to manage custom state transitions and tween animations.
  • Implement automated widget tests to verify that animation state machines and value transitions execute correctly.
  • Refactor static UI components to use implicit animation widgets, such as AnimatedContainer and AnimatedOpacity, for smooth state transitions.
  • Implement shared element routing transitions across navigation boundaries using Hero animation widgets.
App developer

Integrate rich animated graphics and shaders into an application

2 tasks

  • Integrate animation libraries, such as "package:rive" or "package:lottie", to render rich vector animations within the application.
  • Implement fragment shaders using GLSL shader programs to render custom GPU-accelerated visual effects and animations.
App developer

Integrate interactive data visualization and charting libraries

3 tasks

  • Research available charting libraries on pub.dev and evaluate which packages support the required chart types and features for the use case.
  • Install a third-party charting package that supports interactive bar charts using official command-line tools ("flutter pub add") rather than manually editing configuration files.
  • Integrate the charting library into the application dashboard to render interactive data visualizations, implementing automated widget tests to verify chart rendering.
App developer

Configure package dependency overrides using Git repositories or local filesystem paths

2 tasks

  • Configure package dependency overrides in "pubspec.yaml" to target a specific remote Git repository and subdirectory path, verifying that all automated tests pass.
  • Configure package dependency overrides in "pubspec.yaml" to link against a local filesystem package path, verifying that all automated tests pass.
App developer

Build an application that renders Material UI on Android and Cupertino UI on iOS

2 tasks

  • Create a new cross-platform Flutter application targeting both Android and iOS.
  • Implement navigation layouts that adaptively render Material Design components on Android and Cupertino components on iOS.
App developer

Implement performant scrolling layouts for long-form content

3 tasks

  • Diagnose vertical layout overflow errors and refactor the component hierarchy to use SingleChildScrollView.
  • Refactor standard scroll views to use CustomScrollView and Sliver components for advanced scrolling effects and header animations.
  • Implement programmatic scroll-to-index functionality for variable-height item lists using scroll controllers or item alignment libraries.
App developer

Build intuitive, validated user forms with polished input UX

2 tasks

  • Implement form validation logic that automatically transfers focus to the first invalid input field when a user submits an incomplete form.
  • Configure text input fields with floating label behavior and error messaging using InputDecoration properties.
App developer

Build an application that communicates with a REST API

4 tasks

  • Implement network calls to fetch and parse JSON payloads from a REST API using "package:http" or "package:dio".
  • Implement robust error handling, network request timeout management, and UI loading state indicators.
  • Offload JSON serialization and deserialization to background worker isolates to prevent main thread stutter and UI frame drops.
  • Generate type-safe API client code and data models automatically from an OpenAPI specification using code generation tools.
App developer

Implement and evaluate state management architectures

6 tasks

  • Implement application state management using standard StatefulWidget and setState mechanisms.
  • Implement application state management using "package:provider" for dependency injection and reactive updates.
  • Implement application state management using "package:riverpod", optionally incorporating "package:flutter_hooks" and code generation.
  • Implement application state management using the Business Logic Component (BLoC) and Cubit patterns from "package:flutter_bloc".
  • Implement application state management using "package:flutter_hooks" to manage widget lifecycle and local state with composable hook functions.
  • Implement stream-based application state management using reactive programming primitives from "package:rxdart".
App developer

Implement local data persistence in an application

4 tasks

  • Implement local persistence for simple key-value data and user preferences using "package:shared_preferences".
  • Implement a structured local relational database using "package:sqflite" or "package:drift".
  • Implement encrypted local storage for sensitive user data and authentication tokens using "package:flutter_secure_storage".
  • Integrate "package:path_provider" to locate platform-specific filesystem directories for application documents and temporary files.
App developer

Offload CPU-intensive computation to background isolates to prevent UI freezing

3 tasks

  • Offload computationally expensive synchronous operations to background worker isolates using Isolate.run.
  • Execute one-shot background computations using the top-level compute function to prevent UI thread blocking.
  • Implement a long-lived background isolate communicating via ReceivePort and SendPort message passing to handle continuous asynchronous processing.
App developer

Adopt code generation tools to reduce boilerplate for models and immutable data classes

3 tasks

  • Configure "package:build_runner" and "package:json_serializable" to generate type-safe JSON serialization code for data models.
  • Integrate "package:freezed" to generate immutable data classes, union types, and value equality boilerplate.
  • Configure automated CI/CD pipelines using "package:build_verify" to ensure generated source code is synchronized with existing data models.
Plugin developer

Diagnose and resolve native platform interop bugs and channel communication errors

3 tasks

  • Analyze native platform channel implementations and Dart bindings to diagnose the root cause of platform communication failures.
  • Instrument platform interop channels with diagnostic logging and execute test runs to isolate native execution errors.
  • Refactor native host code and Dart channel handlers to resolve platform interop exceptions and restore reliable communication.
Plugin developer

Design a unified, well-documented cross-platform API surface for plugin consumers

3 tasks

  • Design a unified, documented Dart API that abstracts native iOS and Android implementation differences for plugin consumers.
  • Structure the plugin package to ensure public APIs encapsulate and hide internal platform interface implementations.
  • Generate HTML API documentation from inline dartdoc comments using command-line tools to verify public API presentation.
Plugin developer

Implement automated native platform test suites (XCTest, Espresso, JUnit) to prevent OS upgrade regressions

1 task

  • Implement automated test suites validating Dart logic and native implementations using XCTest for iOS and JUnit or Espresso for Android.
Plugin developer

Maintain high-quality published packages with rigorous semantic versioning, detailed changelogs, and responsiveness to SDK updates

1 task

  • Manage semantic versioning, maintain changelogs, achieve high pub.dev quality scores, and publish package releases compatible with current Flutter SDK versions.
Plugin developer

Adopt optimal native interop mechanisms (FFI, Pigeon, JS Interop) based on performance and platform requirements

4 tasks

  • Migrate Pigeon-based platform channels to Foreign Function Interface (FFI) bindings for performance-critical or synchronous native calls.
  • Replace manual platform channel boilerplate with type-safe message passing code generated by "package:pigeon".
  • Create type-safe bindings between Dart and JavaScript using "dart:js_interop" and extension types to integrate with browser APIs and external JavaScript libraries.
  • Ensure native memory allocations (malloc, calloc, FFI structs, OpenGL handles, file descriptors) are properly released using NativeFinalizer and the Finalizable interface.
Plugin developer

Extend an existing federated plugin architecture to support a new target platform

4 tasks

  • Implement native platform support for an additional operating system within an existing plugin, verifying that all application-facing integration tests pass.
  • Verify the new platform implementation by running automated test suites against the application-facing package.
  • Map C language data types (integers, structs, and pointers) to "dart:ffi" types, utilizing AbiSpecificInteger for platform-dependent type sizing.
  • Refactor a monolithic plugin into a federated architecture consisting of separate application-facing, platform interface, and platform implementation packages.
Plugin developer

Implement automated cross-platform integration tests for plugins using modern testing frameworks

3 tasks

  • Implement automated cross-platform integration tests using "package:patrol" to verify plugin functionality across native environments.
  • Configure an automated CI/CD pipeline to execute plugin integration tests on every pull request and prior to release publication.
  • Develop comprehensive integration test suites that achieve full test coverage of native platform plugin functionality.
Full-stack developer

Implement user authentication flows and UI

3 tasks

  • Define the architectural requirements, user experience flows, and edge-case handling for application authentication.
  • Implement secure user authentication and registration workflows connecting the frontend UI to the authentication service.
  • Implement automated unit, widget, and integration test suites to verify all authentication and session management workflows.
Full-stack developer

Integrate push notification services into an application

2 tasks

  • Integrate "package:firebase_messaging" to enable push notifications across mobile and web platforms.
  • Implement notification event listeners and handlers for foreground, background, and terminated application lifecycle states.
Full-stack developer

Integrate third-party authentication providers into an application

2 tasks

  • Integrate "package:google_sign_in" to enable single sign-on authentication.
  • Implement complete authentication state machines managing sign-in, sign-out, session persistence, and OAuth token refresh workflows.
Full-stack developer

Integrate cloud file storage into an application

2 tasks

  • Integrate "package:firebase_storage" into the application to enable cloud storage capabilities.
  • Implement user flows and repository methods to upload, download, and delete cloud storage files.
Full-stack developer

Integrate crash reporting, error tracking, and production telemetry

2 tasks

  • Integrate Firebase Crashlytics ("package:firebase_crashlytics") to capture and monitor real-time fatal exception reports.
  • Implement custom error logging and non-fatal exception tracking to record application telemetry and diagnostic metadata.
Full-stack developer

Integrate AWS Amplify authentication, cloud storage, and backend APIs into an application

1 task

  • Integrate AWS Amplify authentication, cloud storage, and API services into the application architecture.
Full-stack developer

Integrate Supabase authentication, database services, and real-time subscriptions into an application

1 task

  • Integrate Supabase authentication, relational database services, and real-time data subscriptions into the application architecture.
Full-stack developer

Build a full-stack Dart web server backend with shared data models between frontend and backend

3 tasks

  • Develop a backend web server and HTTP API routing layer using "package:shelf".
  • Implement server-side logic or Google Cloud Functions to process file uploads and store metadata in Firebase.
  • Design and implement a shared monorepo workspace structure to allow seamless data model reuse between Dart frontend and backend services.
Full-stack developer

Implement API versioning and backward compatibility checks between frontend applications and backend services

2 tasks

  • Configure automated CI/CD deployment pipelines to verify that the target backend API version is active prior to releasing client applications.
  • Implement a dedicated application deprecation screen that informs users when their client version is no longer supported by backend API services.
Full-stack developer

Develop Google Cloud Functions in Dart using the Genkit SDK

1 task

  • Develop and deploy serverless Google Cloud Functions written in Dart using the Genkit framework ("package:genkit").
App developer

Add internationalization (i18n) and localization (l10n) support to an application

2 tasks

  • Configure supported languages and regional locales within the application localization settings.
  • Verify that the codebase implements standard Flutter internationalization practices using ARB files and generated localization delegates.
Hybrid developer

Embed interactive Flutter applications and widgets within existing HTML or React web pages

3 tasks

  • Build a server-rendered or static website in Dart using the Jaspr web framework ("package:jaspr").
  • Embed a compiled Flutter web application as an interactive component within an existing React web application.
  • Embed multiple interactive Flutter widgets across a standard HTML web page, utilizing Flutter multi-view mode to optimize rendering performance and resource consumption.
Hybrid developer

Integrate Flutter modules into existing native Android and iOS applications using Add-to-app

2 tasks

  • Integrate a cached FlutterEngine and FlutterActivity into an existing native Android application using Flutter Add-to-app workflows.
  • Integrate a cached FlutterEngine and FlutterViewController into an existing native iOS application using Flutter Add-to-app workflows.
Hybrid developer

Implement seamless cross-layer navigation and state synchronization between native host apps and embedded Flutter modules

3 tasks

  • Configure native host applications to pre-warm and cache the FlutterEngine during application startup to eliminate initialization latency.
  • Implement bidirectional navigation stacks where users transition between native Swift screens and embedded Flutter modules, ensuring native gesture back-swipes behave naturally.
  • Synchronize active session tokens, visual theme preferences, and user state from the host native application into embedded Flutter modules to provide a seamless user experience.
Hybrid developer

Build platform-specific home screen widgets (for iOS WidgetKit and Android) that share data with the host application

3 tasks

  • Scaffold and configure native home screen widget extensions for iOS using WidgetKit and for Android using AppWidgets.
  • Implement shared local storage using App Groups on iOS and SharedPreferences on Android to synchronize data between the Flutter application and native widgets.
  • Trigger programmatic background updates and timeline reloads for native home screen widgets directly from Dart application logic.
App developer

Identify and refactor architectural anti-patterns in the codebase

1 task

  • Analyze the codebase to identify and refactor architectural anti-patterns, such as building complex widget trees inside helper methods rather than separate widget classes.
Tech lead / architect

Audit and migrate codebases away from deprecated frameworks, libraries, and SDK APIs

1 task

  • Analyze the codebase to identify and migrate deprecated API usage, including Material Design 2 components, direct window references in "dart:ui", and legacy ThemeData styling properties.
Tech lead / architect

Automate multi-flavor application build, configuration, and distribution pipelines

2 tasks

  • Configure multi-flavor build schemes across iOS and Android to support distinct application names, bundle identifiers, and launcher icons for staging and production environments.
  • Implement an automated CI/CD distribution pipeline to build and deploy application binaries to internal testing tracks or distribution services.
Tech lead / architect

Upgrade and migrate legacy Flutter applications to the latest SDK version

2 tasks

  • Audit the local Flutter SDK installation and upgrade safely using version management tools ("fvm") or system package managers.
  • Execute "dart fix" to update deprecated syntax and resolve breaking API changes across the codebase.
Tech lead / architect

Extend an existing application to support an additional target platform

2 tasks

  • Audit existing codebase capabilities and third-party plugins to determine feature compatibility with the target platform.
  • Execute official platform scaffolding commands to generate target platform projects and verify dependency compatibility.
App developer

Implement new application features utilizing modern language capabilities and defensive coding practices

2 tasks

  • Enforce defensive coding by adding runtime assert statements to validate constructor and function parameter boundaries.
  • Refactor function signatures to return structured, type-safe multiple values using modern Dart Record types.
App developer

Implement custom canvas drawing and custom painters for specialized UI components

1 task

  • Implement a custom component utilizing CustomPaint and Canvas primitives to render specialized graphics above or below child widget layers.
Plugin developer

Design and develop a new cross-platform plugin from scratch, selecting the appropriate native interop mechanism

1 task

  • Evaluate whether Foreign Function Interface (FFI) bindings or asynchronous MethodChannels provide the optimal architectural foundation for a new cross-platform plugin.
App developer

Set up and configure a complete cross-platform Flutter development environment

3 tasks

  • Install and configure Xcode, command-line tools, and CocoaPods on a macOS development environment to compile for all supported Flutter target platforms.
  • Set up and configure a Windows development environment for Flutter with necessary dependencies to compile for all supported non-Apple target platforms.
  • Set up and configure a Linux development environment for Flutter with necessary dependencies to compile for all supported non-Apple target platforms.
App developer

Build a responsive Flutter Web frontend for an Enterprise Resource Planning (ERP) system

5 tasks

  • Develop a responsive Flutter web frontend that dynamically adapts between desktop browser layouts and mobile web layouts.
  • Configure the web URL routing strategy (hash-based or path-based) according to target web hosting platform requirements.
  • Configure the web build pipeline to compile to WebAssembly (Wasm) for high-performance browser execution.
  • Configure Progressive Web App (PWA) manifest and service worker features to enable offline support and desktop installation.
  • Implement browser API integrations and JavaScript interop using "package:web" and modern Dart type-safe JS interop mechanisms.
App developer

Build adaptive UI layouts that dynamically adjust to platform conventions and input methods (touch, mouse, keyboard, stylus)

6 tasks

  • Implement adaptive navigation that transitions between a bottom navigation bar on compact screens and a side NavigationRail on expanded displays, sharing routing destinations.
  • Optimize the interface for mouse and stylus input by utilizing Material Design 3 components with built-in hover and focus states.
  • Refactor custom scrollable components using Listener widgets to support mouse scroll wheel and trackpad navigation.
  • Implement keyboard tab navigation and visible focus highlights on custom interactive components using FocusableActionDetector and FocusTraversalGroup.
  • Configure application-wide keyboard shortcuts using Shortcuts and Actions widgets, ensuring shortcuts are disabled during text input.
  • Adjust widget VisualDensity dynamically based on active input mode to optimize touch target sizes versus mouse precision sizing.
App developer

Migrate application architecture between state management solutions

6 tasks

  • Refactor the codebase to use "package:riverpod" rather than StatefulWidgets.
  • Refactor the codebase to use "package:provider" rather than StatefulWidgets.
  • Refactor the codebase to use "package:provider" rather than custom InheritedWidgets.
  • Migrate existing state management from "package:provider" to "package:riverpod".
  • Migrate existing state management from "package:provider" to the BLoC ("package:flutter_bloc") architecture.
  • Refactor the codebase to manage reactive state using "package:rxdart" rather than StatefulWidgets.
App developer

Diagnose, debug, and resolve runtime exceptions and network defects

3 tasks

  • Reproduce a reported defect in a failing test, then trace the root cause using the Dart debugger and Flutter DevTools.
  • Diagnose and resolve common runtime exceptions (null errors, late init failures, RangeErrors, invalid setState calls).
  • Diagnose and resolve failed HTTP requests (non-200 status codes, timeouts, JSON deserialization failures).
App developer

Refactor application code to improve modularity, component reusability, and architectural maintainability

3 tasks

  • Extract repeated widget trees into reusable components and consolidate shared colors, spacing, and text styles into central theme constants.
  • Refactor large Dart classes into smaller units, separating business logic from widget presentation.
  • Extract shared UI behavior and state logic into reusable Dart mixins.
App developer

Call native platform APIs directly using MethodChannel and EventChannel implementations on Android and iOS

2 tasks

  • Implement one-shot communication between Dart and native platforms via MethodChannel (e.g., reading battery level or triggering haptic feedback), writing handlers in Kotlin for Android and Swift for iOS.
  • Stream continuous native events into Dart via EventChannel (e.g., sensor data or network connectivity state).