flutter-setup-declarative-routing

Configure declarative routing and deep linking in Flutter apps using go_router.

1|Updated Aug 14, 2026
One-click install
npx skills add https://github.com/sohampawar1866/zeromile-go --skill flutter-setup-declarative-routing-sohampawar1866
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: flutter-setup-declarative-routing
Source: https://github.com/sohampawar1866/zeromile-go/tree/main/.agents/skills/flutter-setup-declarative-routing
Command: npx skills add https://github.com/sohampawar1866/zeromile-go --skill flutter-setup-declarative-routing-sohampawar1866

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires go_router.

What problem does it solve? Setting up URL-based navigation, deep linking, and nested navigation in Flutter requires coordinating Dart router configuration with platform-specific Android and iOS settings, which is error-prone when done manually. ## Core Features & Use Cases - Declarative Router Setup: Configure GoRouter with MaterialApp.router, path URL strategy, redirects, and error handling. - Platform Deep Linking: Apply Android manifest and assetlinks.json configuration plus iOS entitlements and apple-app-site-association hosting, with ADB and xcrun validation commands. - Nested Navigation: Implement persistent bottom navigation shells using StatefulShellRoute that preserve per-branch state. - Use Case: You are building a Flutter web and mobile app that must open https://yourdomain.com/details/123 directly into the correct screen on both Android and iOS while keeping a stateful bottom navigation bar. ## Quick Start Set up go_router declarative routing with deep linking for Android and iOS in my Flutter app.

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 set up go_router in a Flutter app?

Add go_router with flutter pub add, define a top-level GoRouter instance with your route tree, and pass it to MaterialApp.router via the routerConfig parameter. Call usePathUrlStrategy in main to remove the hash fragment from web URLs.

How to enable deep linking in Flutter on Android and iOS?

On Android, add an intent filter with autoVerify in AndroidManifest.xml and host assetlinks.json at your domain's .well-known path. On iOS, enable FlutterDeepLinkingEnabled in Info.plist, add associated domains to entitlements, and host the apple-app-site-association file.

How do I test Flutter deep links on Android and iOS?

On Android, use adb shell with am start and an ACTION_VIEW intent targeting your URL and package name. On iOS, run xcrun simctl openurl booted followed by the deep link URL on a booted simulator.

Does go_router support persistent bottom navigation bars?

Yes, go_router supports persistent shells through StatefulShellRoute.indexedStack, which keeps each navigation branch's state alive. You build the shell UI with a StatefulNavigationShell and switch branches via navigationShell.goBranch.

Why does Flutter deep linking conflict with third-party plugins on iOS?

Flutter's built-in deep link handler can conflict with plugins like app_links that intercept the same URLs. Set FlutterDeepLinkingEnabled to NO in Info.plist when using a third-party deep linking plugin to prevent double handling.