wiredashio / wiredash-sdk

Interactive user feedback tool for Flutter 🎉
https://pub.dev/packages/wiredash
Other
514 stars 66 forks source link

Multiple Routes get pushed when starting/closing Feedback #366

Closed dario-digregorio closed 1 month ago

dario-digregorio commented 1 month ago

Describe the bug I am currently facing a bug when starting and closing feedback. It seems like when opening/closing the feedback there get multiple routes pushed. I am using the default Wiredash configuration and I am also using the auto_route library for Routing. See the video. If needed I can create a example repo.

Wiredash SDK Info wiredash: ^2.2.2 with flutter

auto_route: ^9.2.2

Flutter SDK

Flutter doctor ```bash flutter doctor Doctor summary (to see all details, run flutter doctor -v): [✓] Flutter (Channel stable, 3.24.3, on macOS 15.0.1 24A348 darwin-arm64, locale en-US) [✓] Android toolchain - develop for Android devices (Android SDK version 35.0.0-rc3) [✓] Xcode - develop for iOS and macOS (Xcode 16.0) [✓] Chrome - develop for the web [✓] Android Studio (version 2024.1) [✓] VS Code (version 1.94.2) [✓] Connected device (5 available) [✓] Network resources ```

Screenshots https://github.com/user-attachments/assets/244febac-9bd7-4f54-9b61-0868f4fd2777

passsy commented 1 month ago

Thanks for reaching out! I hope I support help you with the integration of Wiredash into your app.

Without any code I can only guess what could cause the router to reset the state

Let me know how it goes 😄

dario-digregorio commented 1 month ago

Okay my bad. It seems like I have misconfigured the deeplinking logic. First of all Wiredash triggers a deeplink routing and instead of returning the passed deepLink Object, I returned DeepLink.defaultPath which just pushes a new route.

config = AppRouter().config(
   deepLinkBuilder: (deepLink) {
   // This is correct  
   return deepLink;
   // This is wrong
   // return DeepLink.defaultPath;
    },
);

I close the issue.

BTW I love your package. Very clean and simple DX and APIs! :)