flutter-setup-declarative-routing

Configure go_router declarative routing and deep linking in Flutter applications.

2.8k|166|Updated Feb 25, 2026
One-click install
npx skills add https://github.com/flutter/agent-plugins --skill flutter-setup-declarative-routing-flutter
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: flutter-setup-declarative-routing
Source: https://github.com/flutter/agent-plugins/tree/main/skills/flutter-setup-declarative-routing
Command: npx skills add https://github.com/flutter/agent-plugins --skill flutter-setup-declarative-routing-flutter

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill addresses the complexity of managing navigation in Flutter applications, specifically solving the challenges of deep linking, browser history support, and maintaining state across complex navigation trees.

Core Features & Use Cases

  • Declarative Routing: Uses the go_router package to define a clean, centralized route tree.
  • Deep Linking: Provides standardized configurations for Android and iOS to handle external URL navigation.
  • Nested Navigation: Implements StatefulShellRoute to manage persistent UI shells like bottom navigation bars while preserving tab state.
  • Use Case: Use this when building a web-enabled Flutter app that requires clean URLs, or a mobile app that needs to handle incoming deep links to specific product detail pages.

Quick Start

Use the flutter-setup-declarative-routing skill to configure a new GoRouter instance with nested navigation and deep linking support for my current project.

Frequently Asked Questions about flutter-setup-declarative-routing

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I configure deep linking in Flutter?

Flutter deep linking is configured using the go_router package to define a centralized route tree, standardized URL strategies, and platform-specific intent handling for Android and iOS external URL navigation.

What is the best way to manage nested navigation and preserve bottom navigation bar state in Flutter?

Nested navigation in Flutter is managed using StatefulShellRoute within go_router, which maintains persistent UI shells like bottom navigation bars while preserving the state of individual tabs during navigation.

Can I use go_router for clean URLs in a web-enabled Flutter app?

Yes, go_router supports path-based URL strategies for web-enabled Flutter apps, ensuring clean URLs and providing browser history support for declarative routing scenarios.

Does declarative routing in Flutter solve browser history and complex navigation tree state issues?

Declarative routing solves browser history and state management challenges by replacing imperative navigation calls with a centralized route tree, maintaining application state across complex navigation flows.

How do I handle platform-specific deep link intents for Android and iOS in Flutter?

Platform-specific deep link intents are handled by configuring Android and iOS intent processing alongside go_router, directing external URLs to specific application pages like product details.