csells / go_router

The purpose of the go_router for Flutter is to use declarative routes to reduce complexity, regardless of the platform you're targeting (mobile, web, desktop), handling deep linking from Android, iOS and the web while still allowing an easy-to-use developer experience.
https://gorouter.dev
441 stars 97 forks source link

pushing routes with `queryParams` #89

Closed csells closed 3 years ago

csells commented 3 years ago

params, queryParams and the extra param are all supported for push but not all are working at the moment. I'll fix asap.

Discussed in https://github.com/csells/go_router/discussions/88

Originally posted by **raulmabe** October 12, 2021 I am trying to push a route (`/search`) with `queryParams` from a top-level route (`/`) but throws `AssertionError` because of the following constraint `assert(identical(match.queryParams, matches.first.queryParams));` in [line 661](https://github.com/csells/go_router/blob/master/lib/src/go_router_impl.dart#L661). Is it incompatible to use push and `queryParams` at the same time? Same happens with the `extra` property
csells commented 3 years ago

fixed in v2.1.2. @raulmabe can you please verify?

elias8 commented 3 years ago

Hi @csells 👋,

I am currently having an issue navigating to a route with a param, where the param could contain a space when navigating. So does this address that issue, or should I submit a new one?

csells commented 3 years ago

That sounds like a new one

raulmabe commented 3 years ago

fixed in v2.1.2. @raulmabe can you please verify?

I can verify I no longer encounter this issue. Thank you 🙌🏼

elias8 commented 3 years ago

I am currently having an issue navigating to a route with a param, where the param could contain a space when navigating. So does this address that issue, or should I submit a new one?

That sounds like a new one

I was using params instead of queryParams which doesn't allow empty spaces 😅. Also, I had the original issue submitted by @raulmabe, which I can also confirm fixed in v2.1.2.

Thanks! 🙏