Skip to content

bug: ionic vue navigating to the same page with a different parameter should still result in a transition #22662

@liamdebeasi

Description

@liamdebeasi

Bug Report

Ionic version:

[ ] 4.x
[x] 5.x

Current behavior:

Given a route of /page/:id, going from /page/1 to page/2 does not result in a nav transition. The new page content simply appears.

Expected behavior:

I would expect that there is a nav transition.

Related code:

We need to implement the following logic in Ionic Vue, similar to how Ionic React does it:

// If a page is transitioning to another version of itself
// we clone it so we can have an animation to show
const match = matchComponent(leavingViewItem.reactElement, routeInfo.pathname, true);
if (match) {
const newLeavingElement = clonePageElement(leavingViewItem.ionPageElement.outerHTML);
if (newLeavingElement) {
this.routerOutletElement.appendChild(newLeavingElement);
await runCommit(enteringViewItem.ionPageElement, newLeavingElement);
this.routerOutletElement.removeChild(newLeavingElement);

insert short code snippets here

Other information:

See: #22658 (comment) and #22658 (comment)

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions